Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt Creator and other tools
  4. [Resolved]qmake i386 vs i386:x86-64

[Resolved]qmake i386 vs i386:x86-64

Scheduled Pinned Locked Moved Qt Creator and other tools
10 Posts 3 Posters 8.3k 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.
  • K Offline
    K Offline
    Kent88
    wrote on last edited by
    #1

    I've recently upgraded my system to ubuntu 12.04 based Mint 13 KDE 64 bit, and I'm trying to test out qmake by compiling a c++ file via 'alphaPlusConnector.pro' (which I've successfully done on a past system) issuing these commands:

    $ qmake -o Makefile ./alphaPlusConnector.pro
    $ make

    and after 'make' I'm getting this error:

    g++ -m64 -Wl,-O1 -o alphaPlusConnector alphaPlusConnector.o -L/usr/lib/x86_64-linux-gnu -lmysqlpp -lQtGui -lQtCore -lpthread
    /usr/bin/ld: i386 architecture of input file `alphaPlusConnector.o' is incompatible with i386:x86-64 output
    collect2: ld returned 1 exit status
    make: *** [alphaPlusConnector] Error 1

    How can I remedy this issue?

    1 Reply Last reply
    0
    • F Offline
      F Offline
      franku
      wrote on last edited by
      #2

      Have you rebuilt the alphaPlusConnector.o with your current compiler, or did you only link the old object (from your past system)?

      This, Jen, is the internet.

      1 Reply Last reply
      0
      • K Offline
        K Offline
        Kent88
        wrote on last edited by
        #3

        I re-ran qmake on 'alphaPlusConnector.pro' on the current system. I assume this rebuilt alphaPlusConnector.o?

        1 Reply Last reply
        0
        • R Offline
          R Offline
          raaghuu
          wrote on last edited by
          #4

          check if the qmake is 32bit or 64bit(just a wild guess, i m a windows user)

          1 Reply Last reply
          0
          • F Offline
            F Offline
            franku
            wrote on last edited by
            #5

            bq. I assume this rebuilt alphaPlusConnector.o?’

            qmake only rebuilds the makefiles. The *.o files are the output of your compiler. After invoking qmake you have to run

            • mingw32-make clean
            • and then mingw32-make

            in order to rebuild everything.

            This, Jen, is the internet.

            1 Reply Last reply
            0
            • K Offline
              K Offline
              Kent88
              wrote on last edited by
              #6

              mingw32? Isn't that for making windows programs?

              1 Reply Last reply
              0
              • F Offline
                F Offline
                franku
                wrote on last edited by
                #7

                Yes, it is. I am a windows user as well. Did you try to rebuild the sourcecode? You have to use make I guess. :-)

                This, Jen, is the internet.

                1 Reply Last reply
                0
                • K Offline
                  K Offline
                  Kent88
                  wrote on last edited by
                  #8

                  but make is where I'm having the problem, it wont let me run make without errors.

                  1 Reply Last reply
                  0
                  • F Offline
                    F Offline
                    franku
                    wrote on last edited by
                    #9

                    bq. I re-ran qmake on ‘alphaPlusConnector.pro’ on the current system. I assume this rebuilt alphaPlusConnector.o?

                    I would have guessed that you used an old build where the objects were already created by the older 32bit compiler. Now you are using the new 64bit tools, but the old objectfile still remains with its old timestamp in its old 32bit form. So make doesn't see the need for rebuilding the objectfiles.

                    The commands

                    make clean will remove the old objectfiles and
                    make will recompile the old files and link everything together.

                    qmake does not compile anything but the .pro file into makefiles (and some other things with ui files).

                    This, Jen, is the internet.

                    1 Reply Last reply
                    0
                    • K Offline
                      K Offline
                      Kent88
                      wrote on last edited by
                      #10

                      Got it, PEBKAC.

                      You were close to right with the problem, franku.

                      Thanks for the replies, appreciate the help.

                      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