| 1 | --- Portfile.orig 2007-12-26 09:00:31.000000000 -0800 |
|---|
| 2 | +++ Portfile 2008-03-30 03:12:12.000000000 -0700 |
|---|
| 3 | @@ -28,8 +28,6 @@ |
|---|
| 4 | |
|---|
| 5 | use_bzip2 yes |
|---|
| 6 | |
|---|
| 7 | -configure.env ABI=32 |
|---|
| 8 | -configure.cflags-append -force_cpusubtype_ALL |
|---|
| 9 | configure.args --infodir=${prefix}/share/info \ |
|---|
| 10 | --enable-shared \ |
|---|
| 11 | --enable-cxx |
|---|
| 12 | @@ -38,14 +36,46 @@ |
|---|
| 13 | |
|---|
| 14 | post-destroot { |
|---|
| 15 | system "ranlib ${destroot}${prefix}/lib/libgmp.a" |
|---|
| 16 | + |
|---|
| 17 | + if {[variant_isset i386_64]} { |
|---|
| 18 | + ui_msg "------------------------------------------------------------" |
|---|
| 19 | + ui_msg "Since the 64-bit variant was used, any program that uses " |
|---|
| 20 | + ui_msg "this version of gmp *must* be compiled with the -m64 switch." |
|---|
| 21 | + ui_msg "------------------------------------------------------------" |
|---|
| 22 | + } elseif {[variant_isset i386]} { |
|---|
| 23 | + ui_msg "------------------------------------------------------------" |
|---|
| 24 | + ui_msg "Since the i386_64 variant was not used, this version of gmp " |
|---|
| 25 | + ui_msg "will be significantly slower; however, it will be " |
|---|
| 26 | + ui_msg "compatible with existing 32-bit programs. " |
|---|
| 27 | + ui_msg "------------------------------------------------------------" |
|---|
| 28 | + } |
|---|
| 29 | } |
|---|
| 30 | |
|---|
| 31 | +use_parallel_build yes |
|---|
| 32 | + |
|---|
| 33 | test.run yes |
|---|
| 34 | test.cmd make |
|---|
| 35 | test.target check |
|---|
| 36 | |
|---|
| 37 | +platform powerpc { |
|---|
| 38 | + configure.args-append ABI=32 |
|---|
| 39 | + configure.cflags-append -force_cpusubtype_ALL |
|---|
| 40 | + configure.cxxflags-append -force_cpusubtype_ALL |
|---|
| 41 | +} |
|---|
| 42 | + |
|---|
| 43 | platform i386 { |
|---|
| 44 | - configure.env-delete ABI=32 |
|---|
| 45 | - configure.args-append --host=none-apple-darwin |
|---|
| 46 | - configure.cflags-delete -force_cpusubtype_ALL |
|---|
| 47 | + configure.args-append --build=x86-apple-darwin ABI=standard |
|---|
| 48 | + configure.cflags-append -m32 |
|---|
| 49 | + configure.cxxflags-append -m32 |
|---|
| 50 | +} |
|---|
| 51 | + |
|---|
| 52 | +variant i386_64 requires i386 conflicts powerpc { |
|---|
| 53 | + # this must match declarations in platform i386 block above. |
|---|
| 54 | + configure.args-delete --build=x86-apple-darwin ABI=standard |
|---|
| 55 | + configure.cflags-delete -m32 |
|---|
| 56 | + configure.cxxflags-delete -m32 |
|---|
| 57 | + |
|---|
| 58 | + configure.args-append --build=x86_64-apple-darwin ABI=64 |
|---|
| 59 | + configure.cflags-append -m64 |
|---|
| 60 | + configure.cxxflags-append -m64 |
|---|
| 61 | } |
|---|