diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2024-01-05 23:28:08 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2024-01-06 08:47:06 +0000 |
commit | 20160dd137a12889723772f4cc013fbf4d5b9af7 (patch) | |
tree | 8c817881dcc4f95f551ab34ae3a04b2772faaf8e | |
parent | 756e18783d8b1986208c4821feb85258b0e1b5ba (diff) | |
download | ports-20160dd137a12889723772f4cc013fbf4d5b9af7.tar.gz ports-20160dd137a12889723772f4cc013fbf4d5b9af7.zip |
devel/libgudev: fix build with clang 18
Clang 18 no longer accepts -export-dynamic, which is a linker option,
resulting in an error building devel/libgudev:
cc -o gudev/libgudev-1.0.so.0.3.0 gudev/libgudev-1.0.so.0.3.0.p/meson-generated_.._gudevenumtypes.c.o gudev/libgudev-1.0.so.0.3.0.p/gudevclient.c.o gudev/libgudev-1.0.so.0.3.0.p/gudevdevice.c.o gudev/libgudev-1.0.so.0.3.0.p/gudevenumerator.c.o -Wl,--as-needed -Wl,--no-undefined -Wl,-O1 -shared -fPIC -Wl,--start-group -Wl,-soname,libgudev-1.0.so.0 -fstack-protector-strong -O2 -pipe -fstack-protector-strong -fno-strict-aliasing -Wl,-rpath,/usr/local/lib -Wl,-rpath-link,/usr/local/lib -export-dynamic -Wl,--version-script,/wrkdirs/share/dim/ports/devel/libgudev/work/libgudev-237/libgudev-1.0.sym /usr/local/lib/libglib-2.0.so /usr/local/lib/libintl.so /usr/local/lib/libgobject-2.0.so /usr/local/lib/libudev.so -Wl,--end-group
cc: error: unknown argument: '-export-dynamic'
Fix this by using the correct spelling, -Wl,--export-dynamic.
PR: 276135
Approved by: x11 (manu)
MFH: 2024Q1
(cherry picked from commit b6807b43f161c18a6d7a5642f817e4bff858d33a)
-rw-r--r-- | devel/libgudev/Makefile | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/devel/libgudev/Makefile b/devel/libgudev/Makefile index 6d9083030bac..f6bb93882a71 100644 --- a/devel/libgudev/Makefile +++ b/devel/libgudev/Makefile @@ -32,6 +32,9 @@ VALA_MESON_ENABLED= vapi VALA_BUILD_DEPENDS= vapigen:lang/vala VALA_VARS= USE+=vala:build +post-patch: + @${REINPLACE_CMD} -e 's|-export-dynamic|-Wl,--export-dynamic|' ${WRKSRC}/gudev/meson.build + add-plist-docs: ${STAGE_COOKIE} cd ${STAGEDIR}; ${FIND} ${DOCSDIR:C@^/@@} -type f | ${SED} -e 's@^@/@' >> ${TMPPLIST} cd ${STAGEDIR}; ${FIND} ${LOCALBASE:C@^/@@}/share/gtk-doc/html -mindepth 2 -type f | ${SED} -e 's@^@/@' >> ${TMPPLIST} |