Ignore:
Timestamp:
Jun 26, 2009, 12:46:18 AM (16 years ago)
Author:
Dmitry A. Kuminov
Message:

qmake: os2/GNUMAKE: There may be things like -L<some_path> in LIBS variables which would appear as -l-L<some_path> in generated Makefiles; fixed now.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/qmake/generators/os2/gnumake.cpp

    r55 r57  
    320320            writeLibDirPart(t);
    321321        QString opt = var("QMAKE_LFLAGS_LIB");
     322        QString optL = var("QMAKE_LFLAGS_LIBDIR");
    322323        QStringList libs = project->values("QMAKE_LIBS");
    323324        for(QStringList::Iterator it = libs.begin(); it != libs.end(); ++it) {
     
    325326            /* lib may be prefixed with -l which is commonly used in e.g. PRF
    326327             * (feature) files on all platforms; remove it before prepending
    327              * the compiler-specific option */
    328             if (lib.startsWith("-l"))
     328             * the compiler-specific option. There is even more weird case
     329             * when LIBS contains library paths prefixed with -L; we detect
     330             * this as well and replace it with the proper option. */
     331            if (lib.startsWith("-L")) {
    329332                lib = lib.mid(2);
    330             t << " " << opt << lib;
     333                t << " " << optL << lib;
     334            } else {
     335                if (lib.startsWith("-l"))
     336                    lib = lib.mid(2);
     337                t << " " << opt << lib;
     338            }
    331339        }
    332340        t << endl;
Note: See TracChangeset for help on using the changeset viewer.