Ticket #32 (closed enhancement: fixed)

Opened 19 months ago

Last modified 19 months ago

Enhanced compiler handling in SConstruct file, multiple target-architectures, VC10 support

Reported by: Carsten Owned by:
Priority: high Milestone:
Component: build system Version: svn-head
Keywords: Cc:
Platform:

Description (last modified by Carsten) (diff)

The attached patch improves the SConstruct file that constructs the software:

  • With MS Visual C/C++, the compiler is now auto-detected (or properly user specified) and subsequent compiler detail settings evaluate the previously detected or specified compiler. Previously, the user was forced to specify the compiler and then the auto-detection could detect and use a different compiler version.
  • With MS Visual C/C++, the target architecture (x86, x86_64 or ia64) is now taken into account. Parallel builds for different architectures are now possible, as each gets a separate different directory tree.
  • Preliminary support for MS Visual C/C++ 10.0 (2010) has been added. It's currently not very useful though --  SCons itself does not yet support the 10.0 version.

The attached patch has been tested on:

  • x86 Windows 2000 with VC 8 (2005), Express Edition.
  • soon: x86 Ubuntu 10.04 Linux with GCC.
  • soon: x86_64 Ubuntu 10.04 Linux with GCC.

Any additional testing and feed-back is welcome! :-)

Attachments

scons_1.patch Download (27.6 KB) - added by Carsten 19 months ago.

Change History

Changed 19 months ago by Carsten

Changed 19 months ago by ronsaldo

I have tested the patch in x86_64 Ubuntu 10.04 Linux with GCC and it works without problems.

Changed 19 months ago by Carsten

  • description modified (diff)

Ronsaldo, thanks for testing!

The patch seems to work better than I initially guessed. ;-)
My tests on my computer at home, running

  • x86 WinVista with VC 9 (2008) Express Edition (and VC 10 (2010) Express Edition, which is not yet officially suppored by SCons), and
  • x86_64 Ubuntu 10.04 Linux with GCC

all went very well.

NVX was so kind as to give me remote access to a x86_64 Win7 VM with VC9 (full) installed, where it worked very well as well (with minor changes).

With all these tests going so well, I'll commit this patch to the repository asap.

One important note for upgraders though: Files CompilerSetup.py and CompilerSetup.pyc should be deleted when the patch is first applied or checked out on a previously used repository. This is a minor one-time issue though that the deletion of the files easily resolves.

Changed 19 months ago by Carsten

  • status changed from new to closed
  • resolution set to fixed

(In [104]) The change improves the build system:

  • With MS Visual C/C++, the compiler is now auto-detected (or properly user specified) and subsequent compiler detail settings evaluate and refine the previously detected or specified compiler. Previously, the user was forced to specify the compiler and then the auto-detection could detect and inadvertently use a different compiler version.
  • With MS Visual C/C++, the target architecture (x86, x86_64 or ia64) is now taken into account. Parallel builds for different architectures are now possible, as each gets a separate directory tree.
  • Preliminary support for MS Visual C/C++ 10.0 (2010) has been added. It's currently not very useful though --  SCons itself does not yet support the 10.0 version.

The attached patch has been successfully tested on various systems as described in ticket #32.
Closes #32.

Update notice: Stale files CompilerSetup.py and CompilerSetup.pyc should be deleted when this changeset is first checked out on a previously used repository.

Note: See TracTickets for help on using tickets.