Opened 9 years ago

Closed 9 years ago

#45852 closed defect (fixed)

physfs @2.0.3 can't build on Leopard/PPC due to rpath (patch included)

Reported by: khepler Owned by: luiji@…
Priority: Normal Milestone:
Component: ports Version: 2.3.2
Keywords: haspatch Cc: ryandesign (Ryan Carsten Schmidt)
Port: physfs

Description

physfs targets 10.2 on PowerPCs, but on Leopard cmake adds -Wl,-rpath to the GCC args which requires 10.5 or newer:

/opt/local/bin/cmake -E cmake_link_script CMakeFiles/physfs.dir/link.txt --verbose=1
/usr/bin/gcc-4.2  -pipe -Os -arch ppc  -DNDEBUG -arch ppc -mmacosx-version-min=10.5 -dynamiclib -Wl,-headerpad_max_install_names  -L/opt/local/lib -Wl,-headerpad_max_install_names -arch ppc -compatibility_version 1.0.0 -current_version 2.0.3 -o libphysfs.2.0.3.dylib -install_name /opt/local/lib/libphysfs.1.dylib CMakeFiles/physfs.dir/physfs.o CMakeFiles/physfs.dir/physfs_byteorder.o CMakeFiles/physfs.dir/physfs_unicode.o CMakeFiles/physfs.dir/platform/os2.o CMakeFiles/physfs.dir/platform/pocketpc.o CMakeFiles/physfs.dir/platform/posix.o CMakeFiles/physfs.dir/platform/unix.o CMakeFiles/physfs.dir/platform/macosx.o CMakeFiles/physfs.dir/platform/windows.o CMakeFiles/physfs.dir/archivers/dir.o CMakeFiles/physfs.dir/archivers/grp.o CMakeFiles/physfs.dir/archivers/hog.o CMakeFiles/physfs.dir/archivers/lzma.o CMakeFiles/physfs.dir/archivers/mvl.o CMakeFiles/physfs.dir/archivers/qpak.o CMakeFiles/physfs.dir/archivers/wad.o CMakeFiles/physfs.dir/archivers/zip.o CMakeFiles/physfs.dir/lzma/C/7zCrc.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zBuffer.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zDecode.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zExtract.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zHeader.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zIn.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zItem.o CMakeFiles/physfs.dir/lzma/C/Archive/7z/7zMethodID.o CMakeFiles/physfs.dir/lzma/C/Compress/Branch/BranchX86.o CMakeFiles/physfs.dir/lzma/C/Compress/Branch/BranchX86_2.o CMakeFiles/physfs.dir/lzma/C/Compress/Lzma/LzmaDecode.o /opt/local/lib/libz.dylib -mmacosx-version-min=10.2 -framework Carbon -framework IOKit -Wl,-rpath,/opt/local/lib 
[ 49%] Built target physfs-static
ld: -rpath can only be used when targeting Mac OS X 10.5 or later
collect2: ld returned 1 exit status

Included patches set minimum build target to 10.5 on Leopard/PPC.

Attachments (2)

Portfile (1.2 KB) - added by khepler 9 years ago.
patch-CMakeLists-Leopard.txt.diff (629 bytes) - added by khepler 9 years ago.
Sets minimum build target to 10.5 on Leopard/PPC

Download all attachments as: .zip

Change History (7)

Changed 9 years ago by khepler

Attachment: Portfile added

Changed 9 years ago by khepler

Sets minimum build target to 10.5 on Leopard/PPC

comment:1 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: ryandesign@… added
Keywords: haspatch added
Owner: changed from macports-tickets@… to luiji@…
Summary: physfs #2.0.3 can't build on Leopard/PPC due to rpath (patch included)physfs @2.0.3 can't build on Leopard/PPC due to rpath (patch included)
Type: enhancementdefect

Is there a way to avoid the use of rpath, for Tiger?

If not, then the current patch needn't be applied conditionally, right?

comment:2 Changed 9 years ago by khepler

cmake doesn't add rpath on Tiger, and the port builds fine on Tiger in its current state.

comment:3 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Ok, then can we just remove that entire IF clause from the CMakeLists.txt?

comment:4 Changed 9 years ago by khepler

That's a more substantial change, and I don't know what side effects that would incur.

comment:5 Changed 9 years ago by ryandesign (Ryan Carsten Schmidt)

Resolution: fixed
Status: newclosed

I think the only side effect should be that compilation succeeds. Committed my proposed change in r139745, which works for me.

Note: See TracTickets for help on using tickets.