update to 3.1
include cmake import file symlink headers in the previous location for compatibility
This commit is contained in:
parent
984ecbe93f
commit
bab4e31b21
5 changed files with 68 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
|
@ -1,2 +1,3 @@
|
|||
/utf8_v2_3_4.zip
|
||||
/utfcpp-2.3.6.tar.gz
|
||||
/utfcpp-3.1.tar.gz
|
||||
|
|
|
|||
2
sources
2
sources
|
|
@ -1 +1 @@
|
|||
SHA512 (utfcpp-2.3.6.tar.gz) = 8dfa4e3e3597ef5a8454adf72a0dc95dbbaf18eb4590e9cecf30c372e3488dd8b405b1d17e3db874bfd9756c7ce2c2961d6096f13b44dea42cc88a801787c459
|
||||
SHA512 (utfcpp-3.1.tar.gz) = 826ac7aa61215ac2144fa3f5edc7f291c3dd25dc69b0c82526840f4651f822515ec262915e1117d975e5c5dd729f6166806a5d397262f59a2b323eb7009671f5
|
||||
|
|
|
|||
12
utf8cpp-noarch.patch
Normal file
12
utf8cpp-noarch.patch
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
diff -up utfcpp-3.1/CMakeLists.txt.noarch utfcpp-3.1/CMakeLists.txt
|
||||
--- utfcpp-3.1/CMakeLists.txt.noarch 2019-10-22 09:52:44.918701226 +0200
|
||||
+++ utfcpp-3.1/CMakeLists.txt 2019-10-22 09:51:52.374148428 +0200
|
||||
@@ -17,7 +17,7 @@ if(UTF8_INSTALL)
|
||||
set(DEF_INSTALL_CMAKE_DIR CMake)
|
||||
else()
|
||||
include(GNUInstallDirs) # define CMAKE_INSTALL_*
|
||||
- set(DEF_INSTALL_CMAKE_DIR ${CMAKE_INSTALL_LIBDIR}/cmake/utf8cpp)
|
||||
+ set(DEF_INSTALL_CMAKE_DIR ${CMAKE_INSTALL_DATADIR}/cmake/utf8cpp)
|
||||
endif()
|
||||
|
||||
install(DIRECTORY source/ DESTINATION include/utf8cpp)
|
||||
32
utf8cpp-use-system-gtest.patch
Normal file
32
utf8cpp-use-system-gtest.patch
Normal file
|
|
@ -0,0 +1,32 @@
|
|||
diff -up utfcpp-3.1/CMakeLists.txt.gtest utfcpp-3.1/CMakeLists.txt
|
||||
--- utfcpp-3.1/CMakeLists.txt.gtest 2019-04-26 23:49:17.000000000 +0200
|
||||
+++ utfcpp-3.1/CMakeLists.txt 2019-10-22 09:44:02.721256016 +0200
|
||||
@@ -32,6 +32,5 @@ endif()
|
||||
|
||||
if(UTF8_TESTS)
|
||||
enable_testing()
|
||||
- add_subdirectory(extern/gtest)
|
||||
add_subdirectory(tests)
|
||||
endif()
|
||||
diff -up utfcpp-3.1/tests/CMakeLists.txt.gtest utfcpp-3.1/tests/CMakeLists.txt
|
||||
--- utfcpp-3.1/tests/CMakeLists.txt.gtest 2019-04-26 23:49:17.000000000 +0200
|
||||
+++ utfcpp-3.1/tests/CMakeLists.txt 2019-10-22 09:46:24.165698530 +0200
|
||||
@@ -16,15 +16,18 @@ target_link_libraries(negative PRIVATE u
|
||||
target_link_libraries(cpp11 PRIVATE
|
||||
utf8::cpp
|
||||
gtest_main
|
||||
+ gtest
|
||||
)
|
||||
target_link_libraries(apitests PRIVATE
|
||||
utf8::cpp
|
||||
gtest_main
|
||||
+ gtest
|
||||
)
|
||||
|
||||
target_link_libraries(noexceptionstests PRIVATE
|
||||
utf8::cpp
|
||||
gtest_main
|
||||
+ gtest
|
||||
)
|
||||
target_compile_options(noexceptionstests PUBLIC -fno-exceptions)
|
||||
|
||||
25
utf8cpp.spec
25
utf8cpp.spec
|
|
@ -2,14 +2,18 @@
|
|||
%global debug_package %{nil}
|
||||
|
||||
Name: utf8cpp
|
||||
Version: 2.3.6
|
||||
Version: 3.1
|
||||
Release: 1%{?dist}
|
||||
Summary: A simple, portable and lightweight library for handling UTF-8 encoded strings
|
||||
License: Boost
|
||||
URL: https://github.com/nemtrif/utfcpp
|
||||
Source0: https://github.com/nemtrif/utfcpp/archive/v%{version}/utfcpp-%{version}.tar.gz
|
||||
Patch0: %{name}-use-system-gtest.patch
|
||||
# put cmake import file in arch-agnostic directory
|
||||
Patch1: %{name}-noarch.patch
|
||||
BuildRequires: cmake3
|
||||
BuildRequires: gcc-c++
|
||||
BuildRequires: gtest-devel
|
||||
|
||||
%description
|
||||
%{summary}.
|
||||
|
|
@ -26,6 +30,7 @@ This project currently only contains header files, which can be found in the
|
|||
Summary: Header files for %{name}
|
||||
BuildArch: noarch
|
||||
Provides: %{name}-static = %{version}-%{release}
|
||||
Requires: cmake-filesystem
|
||||
|
||||
%description devel
|
||||
%{summary}.
|
||||
|
|
@ -40,6 +45,9 @@ This project currently only contains header files, which can be found in the
|
|||
|
||||
%prep
|
||||
%setup -q -n utfcpp-%{version}
|
||||
%patch0 -p1 -b .gtest
|
||||
%patch1 -p1 -b .noarch
|
||||
#%%patch10 -p1
|
||||
mkdir build
|
||||
|
||||
%build
|
||||
|
|
@ -56,9 +64,12 @@ pushd build
|
|||
%make_install
|
||||
popd
|
||||
pushd %{buildroot}%{_includedir}
|
||||
mv utf8cpp/utf8{,.h} .
|
||||
ln -s utf8cpp/utf8.h ./
|
||||
mkdir utf8
|
||||
for f in {{un,}checked,core,cpp11}.h ; do
|
||||
ln -s ../utf8cpp/utf8/${f} utf8/
|
||||
done
|
||||
popd
|
||||
rm -r %{buildroot}%{_libdir}/cmake/utf8cpp
|
||||
|
||||
%check
|
||||
pushd build
|
||||
|
|
@ -71,9 +82,17 @@ popd
|
|||
%dir %{_includedir}/utf8
|
||||
%{_includedir}/utf8/checked.h
|
||||
%{_includedir}/utf8/core.h
|
||||
%{_includedir}/utf8/cpp11.h
|
||||
%{_includedir}/utf8/unchecked.h
|
||||
%{_includedir}/utf8cpp
|
||||
%{_datadir}/cmake/utf8cpp
|
||||
|
||||
%changelog
|
||||
* Tue Oct 22 2019 Dominik 'Rathann' Mierzejewski <rpm@greysector.net> - 3.1-1
|
||||
- update to 3.1
|
||||
- include cmake import file
|
||||
- symlink headers in the previous location for compatibility
|
||||
|
||||
* Mon Oct 21 2019 Dominik 'Rathann' Mierzejewski <rpm@greysector.net> - 2.3.6-1
|
||||
- update to 2.3.6
|
||||
- new upstream location
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue