Results 1 to 10 of 10

Thread: How to know if 32 or 64 linux.

Threaded View

Previous Post Previous Post   Next Post Next Post
  1. #9
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: How to know if 32 or 64 linux.

    Assuming you are are using GCC on Linux then these predefined macros may be useful:
    Qt Code:
    1. __i386__ You're compiling for a 32-bit Intel
    2. __x86_64__ You're compiling for a 64-bit Intel
    3. __ppc__ You're compiling for a 32-bit PowerPC
    4. __ppc64__ You're compiling for a 64-bit PowerPC
    5.  
    6. __LP64__ possibly an indicator of 64-bitness
    To copy to clipboard, switch view to plain text mode 
    You can see what your GCC defines with:
    Qt Code:
    1. cpp -dM -E < /dev/null
    To copy to clipboard, switch view to plain text mode 
    You could also peruse qglobal.h for hints as to how the Qt system does it.

    http://predef.sourceforge.net/ is also very useful

  2. The following user says thank you to ChrisW67 for this useful post:

    nomadscarecrow (16th July 2010)

Similar Threads

  1. another ide on linux ?
    By hcetiner in forum Newbie
    Replies: 3
    Last Post: 13th May 2010, 14:38
  2. linux-ipaq-g++ Vs linux-arm-g++
    By alejo in forum Installation and Deployment
    Replies: 0
    Last Post: 22nd February 2010, 00:23
  3. using win or linux?
    By mattia in forum Newbie
    Replies: 3
    Last Post: 19th March 2008, 21:46
  4. IDE for Linux
    By steg90 in forum Newbie
    Replies: 22
    Last Post: 15th July 2007, 15:27
  5. From MAC OS X to Linux
    By DoNaLd in forum Qt Programming
    Replies: 7
    Last Post: 7th July 2006, 19:46

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.