Hello community, here is the log from the commit of package cld2 for openSUSE:Factory checked in at 2020-08-01 12:33:49 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/cld2 (Old) and /work/SRC/openSUSE:Factory/.cld2.new.3592 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "cld2" Sat Aug 1 12:33:49 2020 rev:4 rq:823869 version:20150820 Changes: -------- --- /work/SRC/openSUSE:Factory/cld2/cld2.changes 2017-10-13 14:16:48.878310685 +0200 +++ /work/SRC/openSUSE:Factory/.cld2.new.3592/cld2.changes 2020-08-01 12:34:03.586654829 +0200 @@ -1,0 +2,8 @@ +Mon Jul 27 13:25:05 UTC 2020 - Matthias Fehring <[email protected]> + +- add pkgconfig file +- cleanup spec file + * remove stuff for compatibility below SLE 12 + * use license tag in files section + +------------------------------------------------------------------- New: ---- cld2.pc.in ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ cld2.spec ++++++ --- /var/tmp/diff_new_pack.23ECYp/_old 2020-08-01 12:34:08.258661092 +0200 +++ /var/tmp/diff_new_pack.23ECYp/_new 2020-08-01 12:34:08.262661097 +0200 @@ -1,7 +1,7 @@ # # spec file for package cld2 # -# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany. +# Copyright (c) 2020 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -12,23 +12,27 @@ # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. -# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# Please submit bugfixes or comments via https://bugs.opensuse.org/ # +%{?!cmake_build:%global cmake_build() make %{?_smp_mflags} VERBOSE=1} + Name: cld2 Version: 20150820 Release: 0 Summary: A library to detect the natural language of text -# https://cld2.googlecode.com/svn/trunk/ +# https://github.com/CLD2Owners/cld2 License: Apache-2.0 Group: Development/Libraries/C and C++ -Url: https://code.google.com/p/cld2/ +URL: https://github.com/CLD2Owners/cld2 Source: %{name}-%{version}.tar.xz # https://code.google.com/p/cld2/issues/detail?id=29 Source2: CMakeLists.txt +Source3: cld2.pc.in BuildRequires: cmake >= 2.8 BuildRequires: gcc-c++ +BuildRequires: pkg-config %description A library that detects over 80 languages in UTF-8 text, based largely @@ -56,49 +60,40 @@ %prep %setup -q cp %{SOURCE2} . +cp %{SOURCE3} . %build -%if 0%{?suse_vesion} >= 1310 +export CXXFLAGS="%{optflags} -std=c++98" %cmake -%else -mkdir build -cd build -# FIXME: you should use %%cmake macros -cmake .. \ - -DCMAKE_INSTALL_PREFIX:PATH=%{_prefix} \ - -DCMAKE_INSTALL_LIBDIR:PATH=%{_libdir} \ - -DINCLUDE_INSTALL_DIR:PATH=%{_includedir} \ - -DLIB_INSTALL_DIR:PATH=%{_libdir} \ - -DCMAKE_BUILD_TYPE=release \ - -DCMAKE_SKIP_RPATH:BOOL=ON \ - -DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \ - -DCMAKE_C_FLAGS:STRING="%{optflags}" \ - -DCMAKE_CXX_FLAGS:STRING="%{optflags} -std=c++98" -%endif -make %{?_smp_mflags} +%cmake_build %install -%if 0%{?suse_version} >= 1310 %cmake_install -%else -cd build -%make_install -%endif %post -n libcld2-0 -p /sbin/ldconfig %postun -n libcld2-0 -p /sbin/ldconfig %files -n libcld2-0 +%if 0%{?suse_version} < 1500 %doc LICENSE +%else +%license LICENSE +%endif %{_libdir}/libcld2.so.* %{_libdir}/libcld2_dynamic.so.* %{_libdir}/libcld2_full.so.* %files devel -%doc LICENSE docs/* +%if 0%{?suse_version} < 1500 +%doc LICENSE +%else +%license LICENSE +%endif +%doc docs/* %{_includedir}/%{name} %{_libdir}/libcld2.so %{_libdir}/libcld2_dynamic.so %{_libdir}/libcld2_full.so +%{_libdir}/pkgconfig/cld2.pc %changelog ++++++ CMakeLists.txt ++++++ --- /var/tmp/diff_new_pack.23ECYp/_old 2020-08-01 12:34:08.294661140 +0200 +++ /var/tmp/diff_new_pack.23ECYp/_new 2020-08-01 12:34:08.294661140 +0200 @@ -9,7 +9,7 @@ internal/compact_lang_det_hint_code.cc internal/compact_lang_det_impl.cc internal/debug.cc - internal/fixunicodevalue.cc + internal/fixunicodevalue.cc internal/generated_entities.cc internal/generated_language.cc internal/generated_ulscript.cc @@ -155,3 +155,11 @@ target_link_libraries(compact_lang_det_test_chrome_16 cld2) target_link_libraries(cld2_unittest_chrome_2 cld2) target_link_libraries(cld2_unittest_avoid_chrome_2 cld2) + +configure_file(${CMAKE_CURRENT_SOURCE_DIR}/cld2.pc.in + ${CMAKE_CURRENT_BINARY_DIR}/cld2.pc + @ONLY +) +install(FILES ${CMAKE_CURRENT_BINARY_DIR}/cld2.pc + DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig +) ++++++ cld2.pc.in ++++++ prefix=@CMAKE_INSTALL_PREFIX@ exec_prefix=${prefix} libdir=@CMAKE_INSTALL_LIBDIR@ includedir=${prefix}/include/cld2 Name: cld2 Description: Compact Language Detector 2 URL: https://github.com/CLD2Owners/cld2 Version: 2 Libs: -L${libdir} -lcld2_full Cflags: -I${includedir} -I${includedir}/internal -I${includedir}/public
