Accepting request 1117919 from home:mantarimay:apps

BuildRequires for contour-terminal

OBS-URL: https://build.opensuse.org/request/show/1117919
OBS-URL: https://build.opensuse.org/package/show/X11:terminals/libunicode?expand=0&rev=1
This commit is contained in:
Marcus Meissner 2023-11-09 13:43:12 +00:00 committed by Git OBS Bridge
commit 73969726fb
6 changed files with 151 additions and 0 deletions

23
.gitattributes vendored Normal file
View File

@ -0,0 +1,23 @@
## Default LFS
*.7z filter=lfs diff=lfs merge=lfs -text
*.bsp filter=lfs diff=lfs merge=lfs -text
*.bz2 filter=lfs diff=lfs merge=lfs -text
*.gem filter=lfs diff=lfs merge=lfs -text
*.gz filter=lfs diff=lfs merge=lfs -text
*.jar filter=lfs diff=lfs merge=lfs -text
*.lz filter=lfs diff=lfs merge=lfs -text
*.lzma filter=lfs diff=lfs merge=lfs -text
*.obscpio filter=lfs diff=lfs merge=lfs -text
*.oxt filter=lfs diff=lfs merge=lfs -text
*.pdf filter=lfs diff=lfs merge=lfs -text
*.png filter=lfs diff=lfs merge=lfs -text
*.rpm filter=lfs diff=lfs merge=lfs -text
*.tbz filter=lfs diff=lfs merge=lfs -text
*.tbz2 filter=lfs diff=lfs merge=lfs -text
*.tgz filter=lfs diff=lfs merge=lfs -text
*.ttf filter=lfs diff=lfs merge=lfs -text
*.txz filter=lfs diff=lfs merge=lfs -text
*.whl filter=lfs diff=lfs merge=lfs -text
*.xz filter=lfs diff=lfs merge=lfs -text
*.zip filter=lfs diff=lfs merge=lfs -text
*.zst filter=lfs diff=lfs merge=lfs -text

1
.gitignore vendored Normal file
View File

@ -0,0 +1 @@
.osc

21
fix-ucd.patch Normal file
View File

@ -0,0 +1,21 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index e40103d..254b75f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -55,7 +55,7 @@ set(LIBUNICODE_UCD_BASE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/_ucd" CACHE PATH "Path
set(LIBUNICODE_UCD_ZIP_DOWNLOAD_URL "https://www.unicode.org/Public/${LIBUNICODE_UCD_VERSION}/ucd/UCD.zip")
set(LIBUNICODE_UCD_ZIP_FILE "${LIBUNICODE_UCD_BASE_DIR}/ucd-${LIBUNICODE_UCD_VERSION}.zip")
-set(LIBUNICODE_UCD_DIR "${LIBUNICODE_UCD_BASE_DIR}/ucd-${LIBUNICODE_UCD_VERSION}")
+set(LIBUNICODE_UCD_DIR "${LIBUNICODE_UCD_BASE_DIR}/ucd-${LIBUNICODE_UCD_VERSION}" CACHE PATH "Path to UCD directory.")
# ----------------------------------------------------------------------------
# code coverage
@@ -96,7 +96,6 @@ message(STATUS "Build mode: ${LIBUNICODE_BUILD_MODE}")
message(STATUS "Build unit tests: ${LIBUNICODE_TESTING}")
message(STATUS "Build tools: ${LIBUNICODE_TOOLS}")
message(STATUS "Using ccache: ${USING_CCACHE_STRING}")
-message(STATUS "Using UCD version: ${LIBUNICODE_UCD_VERSION}")
message(STATUS "Using UCD directory: ${LIBUNICODE_UCD_DIR}")
message(STATUS "Enable clang-tidy: ${ENABLE_TIDY} (${CMAKE_CXX_CLANG_TIDY})")
message(STATUS "------------------------------------------------------------------------------")

3
libunicode-0.3.0.tar.gz Normal file
View File

@ -0,0 +1,3 @@
version https://git-lfs.github.com/spec/v1
oid sha256:ddc44bc29c9f3e0001ab84facec250f57f5219dd9f9eca3811aa04293087b1ef
size 88746

5
libunicode.changes Normal file
View File

@ -0,0 +1,5 @@
-------------------------------------------------------------------
Tue Oct 10 20:30:32 UTC 2023 - Muhammad Akbar Yanuar Mantari <mantarimay@pm.me>
- Initial package

98
libunicode.spec Normal file
View File

@ -0,0 +1,98 @@
#
# spec file for package libunicode
#
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%define ver 0
%define mayor 2
%define lname libunicode%{ver}_%{mayor}
%define sover %{ver}.%{mayor}
Name: libunicode
Version: 0.3.0
Release: 0
Summary: Modern C++17 Unicode library
License: Apache-2.0
URL: https://github.com/contour-terminal/libunicode
Source0: %{url}/archive/v%{version}/%{name}-%{version}.tar.gz
# fix to enable the customized defined ucd path
Patch0: fix-ucd.patch
BuildRequires: ccache
BuildRequires: cmake
BuildRequires: fmt-devel
BuildRequires: gcc-c++
BuildRequires: range-v3-devel
BuildRequires: unicode-ucd
BuildRequires: Catch2-2-devel
ExclusiveArch: x86_64 aarch64
%description
The goal of libunicode library is to bring painless unicode support to C++
with simple and easy to understand APIs. The API naming conventions are chosen
to look familiar to those using the C++ standard libary.
%package -n %{lname}
Summary: Library files for %{name}
%description -n %{lname}
The %{name} package contains libraries files for applications
that use %{name}
%package devel
Summary: Development files for %{name}
Requires: %{lname} = %{version}
%description devel
The %{name}-devel package contains libraries and header files for
developing applications that use %{name}.
%package tools
Summary: Tools for %{name}
Requires: %{lname} = %{version}
%description tools
The %{name}-tools package contains tools about %{name}.
%prep
%autosetup
%build
%cmake -DLIBUNICODE_UCD_DIR=%{_datadir}/unicode/ucd
%cmake_build
%install
%cmake_install
%check
%ctest
%ldconfig_scriptlets -n %lname
%files -n %{lname}
%license LICENSE
%doc README.md Changelog.md
%{_libdir}/%{name}*.so.%{sover}*
%files devel
%dir %{_includedir}/%{name}
%{_includedir}/%{name}/*.h
%dir %{_libdir}/cmake/%{name}
%{_libdir}/cmake/%{name}/*.cmake
%{_libdir}/%{name}*.so
%files tools
%{_bindir}/unicode-query
%changelog