This is a discussion on 64 bit Compilation problem on Solaris 8 within the IPFilter forums, part of the System Security and Security Related category; Hi, I have tried to compile ipfilter 4.1.9 with gcc 3.4.2 from sunfreeware.com, and the ...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
Hi,
I have tried to compile ipfilter 4.1.9 with gcc 3.4.2 from sunfreeware.com, and the script buildsunos was telling me "No 64 bit capable compiler was found" It turns out that (unless I am wrong) that part of the script is not correct : case "$CC" in *gcc*) # gcc XARCH32="" XARCH64="-m64 -mcmodel=medlow" XARCH64_i386="-m64 -mcmodel=kernel -mno-red-zone -ffreestanding" ;; *) # Sun C XARCH32="-Xa -xildoff" XARCH64_sparc="$XARCH32 -xarch=v9 -xchip=ultra -dalign -xcode=abs32" XARCH64_i386="$XARCH32 -xarch=amd64 -xcode=abs32" ;; esac XARCH64="`eval echo '$XARCH64_'$cpu`" The last line of that part reinitializes XARCH64 with XARCH64_$cpu. On Sparc solaris, $cpu=sparc. So XARCH64 = $XARCH64_sparc. But that variable does not exist in the gcc part of the case test (but it exists in the Sun C part). So XARCH64 becomes empty and the script thinks gcc can not compile 64 bits executables. So I just added XARCH64_sparc="-m64 -mcmodel=medlow" in the gcc part of the case test, and everything goes well. I searched with google but did not find anyone having that problem and solving it that way, so I thought it would be a good idea to tell you so you can correct it for future versions if it's a bug. Hope it helps. Regards, Guillaume Courtois |