From f455250253f4f15908c3a359c889548758a5ac80908e3a40efff99997afddae4 Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Wed, 7 Sep 2022 09:21:29 +0000 Subject: [PATCH 1/2] - Rework static library removal & building procedure to identify new static libs. (libGenericCodeGen.so and libMachineIndependent.so are now added) OBS-URL: https://build.opensuse.org/package/show/X11:Wayland/glslang?expand=0&rev=96 --- glslang.changes | 7 +++++++ glslang.spec | 12 ++++++++---- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/glslang.changes b/glslang.changes index 043a2da..674ea11 100644 --- a/glslang.changes +++ b/glslang.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Wed Sep 7 09:20:41 UTC 2022 - Jan Engelhardt + +- Rework static library removal & building procedure to identify + new static libs. (libGenericCodeGen.so and + libMachineIndependent.so are now added) + ------------------------------------------------------------------- Mon Aug 22 23:01:23 UTC 2022 - Jan Engelhardt diff --git a/glslang.spec b/glslang.spec index 9670720..5fcce43 100644 --- a/glslang.spec +++ b/glslang.spec @@ -79,7 +79,6 @@ compressor's dictionary can find better cross module commonality. %global _lto_cflags %{_lto_cflags} -ffat-lto-objects %cmake_install b="%buildroot" -find "$b" -type f -name "*.a" -print -delete mkdir -p "$b/%_includedir" cp -a SPIRV glslang "$b/%_includedir/" find "$b/%_includedir/" -type f ! -iname "*.h" -a ! -iname "*.hpp" -print -delete @@ -87,10 +86,13 @@ ln -s SPIRV/spirv.hpp "$b/%_includedir/" find "$b/%_includedir/" -type f -exec chmod a-x "{}" "+" cp build/StandAlone/libglslang-default-resource-limits.so "$b/%_libdir/" -# 3rd party programs use -lOGLCompiler (because pristine glslang ships .a files), +# 3rd party programs use -lOGLCompiler (because pristine glslang shipped .a files), # so satisfy them under our shared build. -ln -s libglslang.so "$b/%_libdir/libOGLCompiler.so" -ln -s libglslang.so "$b/%_libdir/libOSDependent.so" +for i in libOGLCompiler libOSDependent libGenericCodeGen libMachineIndependent; do + ln -s libglslang.so "$b/%_libdir/$i.so" + rm -f "$b/%_libdir/$i.a" +done + %fdupes %buildroot/%_prefix %post -n %lname -p /sbin/ldconfig @@ -104,7 +106,9 @@ ln -s libglslang.so "$b/%_libdir/libOSDependent.so" %_bindir/spirv* %_libdir/cmake/ %_libdir/*resource*.so +%_libdir/libGenericCodeGen.so %_libdir/libHLSL.so +%_libdir/libMachineIndependent.so %_libdir/libOGLCompiler.so %_libdir/libOSDependent.so %_libdir/libSPIRV.so From ce24681daebf5d701f19eab157b1ddedb28202b2f385835126c313d4a02d3446 Mon Sep 17 00:00:00 2001 From: Jan Engelhardt Date: Fri, 9 Sep 2022 11:50:59 +0000 Subject: [PATCH 2/2] Accepting request 1002289 from home:rhabacker:branches:games - Adjust the cmake support files to use the shared libraries added from the latest changes OBS-URL: https://build.opensuse.org/request/show/1002289 OBS-URL: https://build.opensuse.org/package/show/X11:Wayland/glslang?expand=0&rev=97 --- glslang.changes | 6 ++++++ glslang.spec | 1 + 2 files changed, 7 insertions(+) diff --git a/glslang.changes b/glslang.changes index 674ea11..15e26e8 100644 --- a/glslang.changes +++ b/glslang.changes @@ -1,3 +1,9 @@ +------------------------------------------------------------------- +Fri Sep 9 10:35:49 UTC 2022 - Ralf Habacker + +- Adjust the cmake support files to use the shared libraries added + from the latest changes + ------------------------------------------------------------------- Wed Sep 7 09:20:41 UTC 2022 - Jan Engelhardt diff --git a/glslang.spec b/glslang.spec index 5fcce43..236dc01 100644 --- a/glslang.spec +++ b/glslang.spec @@ -92,6 +92,7 @@ for i in libOGLCompiler libOSDependent libGenericCodeGen libMachineIndependent; ln -s libglslang.so "$b/%_libdir/$i.so" rm -f "$b/%_libdir/$i.a" done +sed -i 's,\.a",\.so",g' %buildroot%{_datadir}/glslang/glslang-targets-*.cmake %fdupes %buildroot/%_prefix