Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Library Issues (SDL)
QtWS25 Last Chance

Library Issues (SDL)

Scheduled Pinned Locked Moved General and Desktop
5 Posts 2 Posters 2.8k Views
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • B Offline
    B Offline
    brynn
    wrote on last edited by
    #1

    I'm about ready to tear my hair out. I'm not used to using Qt, and I'm using a privately developed SDK for programming a Multitouch device. I transferred my code from an old computer to a new one running Lion, and while it worked in Snow Leopard and the environment I configured there, it's now throwing up errors over the stupidest things.

    So, my issue. I'm not familiar with the .pro file, and I will not pretend to being comfortable with its set up. Here are the contents of the file:
    @SOURCES += Main.cpp
    tilewidget.cpp
    activewidget.cpp
    scorewidget.cpp
    tilehome.cpp

    CONFIG -= qt

    TARGET = HelloWorld

    macx {
    LIBS += -framework Nimble
    LIBS += -framework Radiant -framework Luminous -framework Screenplay
    LIBS += -framework MultiTouch -framework MultiWidgets
    LIBS += -framework Valuable -framework Fluffy -framework Poetic
    LIBS += -lSDL -lSDLmain

    LIBS += -framework Cocoa
    }

    HEADERS +=
    tilewidget.hpp
    activewidget.hpp
    scorewidget.hpp
    tilehome.hpp@

    When I try to compile the code, I get the following error from the compiler.

    @09:49:00: Running build steps for project HelloWorldExt...
    09:49:00: Configuration unchanged, skipping qmake step.
    09:49:01: Starting: "/usr/bin/make" -w
    make: Entering directory /Users/mwl36/Desktop/Source' g++-4.2 -headerpad_max_install_names -arch x86_64 -Xarch_x86_64 -mmacosx-version-min=10.5 -o HelloWorld.app/Contents/MacOS/HelloWorld Main.o tilewidget.o activewidget.o scorewidget.o tilehome.o -framework Nimble -framework Radiant -framework Luminous -framework Screenplay -framework MultiTouch -framework MultiWidgets -framework Valuable -framework Fluffy -framework Poetic -lSDL -lSDLmain -framework Cocoa ld: library not found for -lSDL collect2: ld returned 1 exit status make: *** [HelloWorld.app/Contents/MacOS/HelloWorld] Error 1 make: Leaving directory /Users/mwl36/Desktop/Source'
    09:49:01: The process "/usr/bin/make" exited with code 2.
    Error while building project HelloWorldExt (target: Desktop)
    When executing build step 'Make'@

    This project file worked perfectly fine on the old computer. I know I'm being peevish about this, but I just don't know what I'm doing wrong. Is the error in the .pro file? Or is it in my library hierarchy?

    1 Reply Last reply
    0
    • H Offline
      H Offline
      Hostel
      wrote on last edited by
      #2

      I'm using a Linux but maybe this will be useful also on Mac.

      Have you installed a sdl and sdl-devel stuff?
      Did you have in PATH a directory where is a SDL lib? If no you could try add this directory.
      @
      LIBS += -L/path/where/is/sdl/lib -lSDL -lSDLmain
      @

      1 Reply Last reply
      0
      • B Offline
        B Offline
        brynn
        wrote on last edited by
        #3

        Hi Hostel,

        Thank you for your response! I did try to do something like that, but it then freaked out about other things. It turns out the darn developers for the SDK didn't tell me they moved things around in their latest release, so I had to adjust my qmake steps. ARGH! Thank you so much for your help!

        1 Reply Last reply
        0
        • H Offline
          H Offline
          Hostel
          wrote on last edited by
          #4

          Hi brynn - I'm happy that you solved your issue.
          Can you write what you had to changed?
          Which SDK was used on old computer and which you are using now?

          1 Reply Last reply
          0
          • B Offline
            B Offline
            brynn
            wrote on last edited by
            #5

            Hi Hostel,

            It was for the Cornerstone SDK; I had been using 1.1.2, and upgraded to 1.2.0. The changes I needed to make were to add the following lines to my .pro file:

            @INCLUDEPATH += /opt/multitouch/include
            QMAKE_LIBDIR += /opt/multitouch/lib@

            After that, everything worked beautifully. :)

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved