Hello community, here is the log from the commit of package laszip for openSUSE:Factory checked in at 2018-01-30 15:42:45 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/laszip (Old) and /work/SRC/openSUSE:Factory/.laszip.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "laszip" Tue Jan 30 15:42:45 2018 rev:3 rq:570380 version:3.1.1 Changes: -------- --- /work/SRC/openSUSE:Factory/laszip/laszip.changes 2016-07-14 09:44:40.000000000 +0200 +++ /work/SRC/openSUSE:Factory/.laszip.new/laszip.changes 2018-01-30 15:42:47.283130434 +0100 @@ -1,0 +2,19 @@ +Wed Jan 24 07:15:06 UTC 2018 - [email protected] + +- Packaging : + + Remove -test package and %check section, tests are no more + autoincluded by upstream + + Adjust FLAGS laszip need -ldl, and be sure %optflags are used + + Create new liblas_api package + + Fix list of file + + Use %license if possible + + move to cmake build following upstream + + Added 0bf1c60.patch fixing .so loading + +- Update to 3.1.1 version. + + sover change from 6 to 3 + + 3.1.0 introduce support for LAZ 1.4 + + New "dll" API replace previous API + + See all changes in Changelog + +------------------------------------------------------------------- Old: ---- laszip-src-2.2.0.tar.bz2 lgpl-2.1.txt New: ---- 0bf1c60.patch laszip-src-3.1.1.tar.gz laszip-src-3.1.1.tar.gz.md5 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ laszip.spec ++++++ --- /var/tmp/diff_new_pack.3zbery/_old 2018-01-30 15:42:47.963098690 +0100 +++ /var/tmp/diff_new_pack.3zbery/_new 2018-01-30 15:42:47.971098316 +0100 @@ -1,7 +1,7 @@ # # spec file for package laszip # -# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany. # Copyright (c) 2014 Ioda-Net Sàrl, Charmoille, Switzerland. Bruno Friedmann (tigerfoot) # # All modifications and additions to the file contributed by third parties @@ -17,16 +17,21 @@ # +# +%define sover 3 + Name: laszip -Version: 2.2.0 +Version: 3.1.1 Release: 0 Summary: Compression library supporting ASPRS LAS format data License: LGPL-2.1+ Group: Development/Libraries/C and C++ Url: http://www.laszip.org/ -Source0: https://github.com/LASzip/LASzip/releases/download/v%{version}/laszip-src-%{version}.tar.bz2 -# Upstream issue pull request Update COPYING #10 on 2014-08-21 -Source2: lgpl-2.1.txt +Source0: https://github.com/LASzip/LASzip/releases/download/%{version}/laszip-src-%{version}.tar.gz +Source1: https://github.com/LASzip/LASzip/releases/download/%{version}/laszip-src-%{version}.tar.gz.md5 +# Upstream [PATCH] Load .so dll on non-apple +Patch0: https://github.com/LASzip/LASzip/commit/0bf1c60.patch +BuildRequires: cmake BuildRequires: gcc-c++ BuildRoot: %{_tmppath}/%{name}-%{version}-build @@ -39,11 +44,11 @@ data. The BSD-licensed libLAS and the LGPL-licensed LASlib can take advantage of LASzip to read and write compressed data. -%package test -Summary: Test for %{name} -Group: Development/Libraries/C and C++ +%package -n lib%{name}%{sover} +Summary: Library files for %{name} +Group: System/Libraries -%description test +%description -n lib%{name}%{sover} A free product of rapidlasso GmbH - quickly turns bulky LAS files into compact LAZ files without information loss. LASzip is a compression library that was developed by Martin Isenburg for compressing ASPRS LAS format data in his @@ -52,27 +57,23 @@ data. The BSD-licensed libLAS and the LGPL-licensed LASlib can take advantage of LASzip to read and write compressed data. -This package contain only the laszippertest tool +This package contain only the dynamic build. -%package -n lib%{name}6 -Summary: Library files for %{name} +%package -n lib%{name}_api%{sover} +Summary: API library files for lib%{name} +# Packager comment are we sure this api can live alone ? +#Requires: lib%%{name}%%{sover} = %%{version} Group: System/Libraries -%description -n lib%{name}6 -A free product of rapidlasso GmbH - quickly turns bulky LAS files into -compact LAZ files without information loss. LASzip is a compression library that -was developed by Martin Isenburg for compressing ASPRS LAS format data in his -LAStools. It has been provided as an LGPL-licensed stand-alone software library -to allow other softwares that handle LAS data to read and write LASzip-compressed -data. The BSD-licensed libLAS and the LGPL-licensed LASlib can take advantage of -LASzip to read and write compressed data. - +%description -n lib%{name}_api%{sover} +API library for %{name} This package contain only the dynamic build. %package devel Summary: Development files for %{name} Group: Development/Libraries/C and C++ -Requires: lib%{name}6 = %{version} +Requires: lib%{name}%{sover} = %{version} +Requires: lib%{name}_api%{sover} = %{version} %description devel Headers and development files for %{name} needed to develop @@ -81,44 +82,62 @@ %prep %setup -q -n laszip-src-%{version} -sed -i 's/-O3//g' ./configure -cp -f %{SOURCE2} COPYING +%patch0 -p1 %build -export CFLAGS="%{optflags} -fno-strict-aliasing -fPIE -pie" -export CXXFLAGS="%{optflags} -fno-strict-aliasing -fPIE -pie" -export LDFLAGS="-Wl,--as-needed -Wl,-z,relro,-z,now -pie" -%configure -make %{?_smp_mflags} +# laszip need dlopen,dlsym,dlclose +%cmake \ + -DCMAKE_C_FLAGS="%{optflags} -fno-strict-aliasing -fPIE -pie" \ + -DCMAKE_C_FLAGS_RELWITHDEBINFO="%{optflags} -fno-strict-aliasing -fPIE -pie" \ + -DCMAKE_CXX_FLAGS="%{optflags} -fno-strict-aliasing -fPIE -pie" \ + -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="%{optflags} -fno-strict-aliasing -fPIE -pie" \ + -DCMAKE_SHARED_LINKER_FLAGS="-Wl,--as-needed -Wl,--no-undefined -Wl,-z,now -Wl,--no-as-needed -ldl" + +make V=1 %{?_smp_mflags} %install -%make_install +%cmake_install # Do not ship any static libraries or .la files find %{buildroot} -type f \( -name '*.a' -o -name '*.la' \) -delete -print +rm -rf %{buildroot}/usr/lib/debug/ -%check -make %{?_smp_mflags} check +# No more available in 3? +#%%check +#make %%{?_smp_mflags} check -%post -n lib%{name}6 -p /sbin/ldconfig -%postun -n lib%{name}6 -p /sbin/ldconfig +%post -n lib%{name}%{sover} -p /sbin/ldconfig +%postun -n lib%{name}%{sover} -p /sbin/ldconfig + +%post -n lib%{name}_api%{sover} -p /sbin/ldconfig +%postun -n lib%{name}_api%{sover} -p /sbin/ldconfig %files devel %defattr(-,root,root) %doc ChangeLog AUTHORS COPYING -%{_includedir}/lasunzipper.hpp -%{_includedir}/laszip.hpp -%{_includedir}/laszipexport.hpp -%{_includedir}/laszipper.hpp +%{_includedir}/%{name}_api_version.h +%dir %{_includedir}/%{name} +%{_includedir}/%{name}/%{name}_api.h %{_libdir}/lib%{name}.so +%{_libdir}/lib%{name}_api.so -%files test +%files -n lib%{name}%{sover} %defattr(-,root,root) -%doc ChangeLog AUTHORS COPYING -%{_bindir}/laszippertest +%doc ChangeLog AUTHORS +%if 0%{?leap_version} >= 420200 || 0%{?suse_version} > 1320 +%license COPYING +%else +%doc COPYING +%endif +%{_libdir}/lib%{name}.so.* -%files -n lib%{name}6 +%files -n lib%{name}_api%{sover} %defattr(-,root,root) -%doc ChangeLog AUTHORS COPYING -%{_libdir}/lib%{name}.so.* +%doc ChangeLog AUTHORS +%if 0%{?leap_version} >= 420200 || 0%{?suse_version} > 1320 +%license COPYING +%else +%doc COPYING +%endif +%{_libdir}/lib%{name}_api.so.* %changelog ++++++ 0bf1c60.patch ++++++ >From d781bf50da33d1789cce3a17777d91e279d0a289 Mon Sep 17 00:00:00 2001 From: Pete Gadomski <[email protected]> Date: Thu, 19 Oct 2017 17:06:55 +0000 Subject: [PATCH] Load .so dll on non-apple This platform checking is...dubious...but this was the Minimum Required To Work on a debian system. --- dll/laszip_api.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dll/laszip_api.c b/dll/laszip_api.c index 007e080..83c09bf 100644 --- a/dll/laszip_api.c +++ b/dll/laszip_api.c @@ -958,8 +958,10 @@ laszip_I32 laszip_load_dll() // Load DLL file #ifdef _WIN32 laszip_HINSTANCE = LoadLibrary(TEXT("LASzip.dll")); -#else +#elif __APPLE__ laszip_HINSTANCE = LoadLibrary("liblaszip.dylib", RTLD_NOW); +#else + laszip_HINSTANCE = LoadLibrary("liblaszip.so", RTLD_NOW); #endif if (laszip_HINSTANCE == NULL) { return 1; ++++++ laszip-src-3.1.1.tar.gz.md5 ++++++ MD5 (laszip-src-3.1.1.tar.gz) = d31fc8b1fc070336a1825beb32595153
