Bug 5291 - Fix 32bit build on 64bit Linux
Status: RESOLVED WONTFIX
Alias: None
Product: iodoom3
Classification: Unclassified
Component: other
Version: unspecified
Hardware: PC Linux
: P3 normal
Assignee: Zachary J. Slater
QA Contact:
URL:
Depends on:
Blocks:
 
Reported: 2011-11-23 13:46 EST by Daniel Gibson
Modified: 2015-08-10 12:14:21 EDT
0 users

See Also:


Attachments
A patch for Sconscript.curl that fixes compilation on 64bit Linux systems (1.34 KB, patch)
2011-11-23 13:46 EST, Daniel Gibson
An updated version of the patch, should be more portable (1.68 KB, patch)
2011-11-24 17:07 EST, Daniel Gibson
zip file that includes the patched win_nanoafx.h (695 bytes, application/zip)
2011-11-24 18:50 EST, Robert Isaac

Description Daniel Gibson 2011-11-23 13:46:38 EST
Created attachment 3006 [details]
A patch for Sconscript.curl that fixes compilation on 64bit Linux systems

Building doom3 on amd64 Linux (tested Debian Squeeze) currently fails, because of two reasons:
 * libcurl isn't built with -m32
 * libcurl's scons-script returns /usr/lib/libz.a (and it's own libs) - on a 64bit system it should be /usr/lib32/libz.a, though.

I fixed this, see attached patch.

Cheers,
- Daniel
Comment 1 Daniel Gibson 2011-11-24 17:07:28 EST
Created attachment 3010 [details]
An updated version of the patch, should be more portable

The old patch had problems on broken distributions like red hat, suse and ubuntu, which seem to store the 32bit libz.a on strange places (see discussions at https://github.com/TTimo/doom3.gpl/pull/11 and https://github.com/TTimo/doom3.gpl/issues/16 )

The updated version fixes this problem by just compiling doom3 with -lz instead of linking in libz.a
Comment 2 Robert Isaac 2011-11-24 18:50:24 EST
Created attachment 3011 [details]
zip file that includes the patched win_nanoafx.h
Comment 3 Zachary J. Slater 2015-08-10 12:14:21 EDT
The only appropriate thing to do with scons is to get rid of it. Sorry.