From 5206a16b9001f5fe0cc200cfa059db1a776c61016c6e3237bee6fcf5069cf141 Mon Sep 17 00:00:00 2001 From: Julius Enriquez Date: Wed, 29 May 2024 02:45:15 +0000 Subject: [PATCH] - Working spec file - Initial spec and source for tvision Significantly cleaner changes file, dependencies have also been cleaned up, devel merged into devel-static, and a patch from an earlier revision has been removed due to being merged upstream: https://github.com/magiblot/tvision/pull/163 OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/tvision?expand=0&rev=5 --- Use-GNUInstallDirs.patch | 53 --------------------------- tvision-0~git630.tar.xz | 3 -- tvision-0~git631.tar.xz | 3 ++ tvision.changes | 77 ++-------------------------------------- tvision.spec | 71 +++++++----------------------------- 5 files changed, 17 insertions(+), 190 deletions(-) delete mode 100644 Use-GNUInstallDirs.patch delete mode 100644 tvision-0~git630.tar.xz create mode 100644 tvision-0~git631.tar.xz diff --git a/Use-GNUInstallDirs.patch b/Use-GNUInstallDirs.patch deleted file mode 100644 index e93a6a7..0000000 --- a/Use-GNUInstallDirs.patch +++ /dev/null @@ -1,53 +0,0 @@ -diff -ruN a/CMakeLists.txt b/CMakeLists.txt ---- a/CMakeLists.txt -+++ b/CMakeLists.txt -@@ -149,6 +149,8 @@ - - option(TV_BUILD_AVSCOLOR "Build AviSynth TermColor plugin" OFF) - -+include(GNUInstallDirs) -+ - tv_message_mp(STATUS "Install path: ${CMAKE_INSTALL_PREFIX}") - tv_message(STATUS "Build Examples: ${TV_BUILD_EXAMPLES}") - if (MAY_BUILD_USING_GPM) -diff -ruN a/examples/CMakeLists.txt b/examples/CMakeLists.txt ---- a/examples/CMakeLists.txt -+++ b/examples/CMakeLists.txt -@@ -25,7 +25,7 @@ - # Until CMake 3.13, 'install' only accepts targets defined - # in the current directory. So install from this function. - if (${app} IN_LIST TVINSTALLAPPS) -- install(TARGETS ${app} RUNTIME DESTINATION bin) -+ install(TARGETS ${app} RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}) - endif() - endfunction() - -diff -ruN a/source/CMakeLists.txt b/source/CMakeLists.txt ---- a/source/CMakeLists.txt -+++ b/source/CMakeLists.txt -@@ -153,14 +153,14 @@ - # - install(TARGETS ${PROJECT_NAME} - EXPORT ${PROJECT_NAME}-config -- ARCHIVE DESTINATION lib -+ ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} - COMPONENT library - ) - - # package configuration - - install(EXPORT ${PROJECT_NAME}-config -- DESTINATION lib/cmake/${PROJECT_NAME} -+ DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${PROJECT_NAME} - NAMESPACE ${PROJECT_NAME}:: - FILE ${PROJECT_NAME}-config.cmake - COMPONENT library -@@ -169,7 +169,7 @@ - # includes - # ./include/tvision and children copied to destination/include/tvision etc... - # --install(DIRECTORY "${PROJECT_SOURCE_DIR}/include/tvision" DESTINATION include) -+install(DIRECTORY "${PROJECT_SOURCE_DIR}/include/tvision" DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}) - - # Build optimization - diff --git a/tvision-0~git630.tar.xz b/tvision-0~git630.tar.xz deleted file mode 100644 index e33176c..0000000 --- a/tvision-0~git630.tar.xz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:878c39f5ab28bf868c5a3711f406a77b1b292c0db851c4ef70db44c2ffba8877 -size 722120 diff --git a/tvision-0~git631.tar.xz b/tvision-0~git631.tar.xz new file mode 100644 index 0000000..796c71f --- /dev/null +++ b/tvision-0~git631.tar.xz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bda76d912323fe6b6011ffd2be9d5bc66652d0bdecd2b51fb9ee7a4ef5608610 +size 722060 diff --git a/tvision.changes b/tvision.changes index 89ea51c..3e16acf 100644 --- a/tvision.changes +++ b/tvision.changes @@ -1,80 +1,7 @@ ------------------------------------------------------------------- -Wed May 22 17:08:17 UTC 2024 - Julius Enriquez +Wed May 29 02:38:31 UTC 2024 - Julius Enriquez -- Changed patch to be compatible with osc -- Use correct library paths - -------------------------------------------------------------------- -Wed May 22 16:50:53 UTC 2024 - Julius Enriquez - -- Add updated tarball - -------------------------------------------------------------------- -Wed May 22 16:34:06 UTC 2024 - Julius Enriquez - -- Add patch to use GNUInstallDirs for CMake - -------------------------------------------------------------------- -Tue May 21 18:30:58 UTC 2024 - Julius Enriquez - -- Split devel into devel and devel-static, put static lib in devel-static -- Move requires and suggests to subpackages - -------------------------------------------------------------------- -Sun May 19 10:24:57 UTC 2024 - Julius Enriquez - -- Add CMake position-independent code build flag for libtvision.a - -------------------------------------------------------------------- -Sat May 18 15:57:12 UTC 2024 - Julius Enriquez - -- Add -fPIC cflag for libtvision.a- - -------------------------------------------------------------------- -Fri May 17 06:08:53 UTC 2024 - Jan Engelhardt - -- Employ a _service file for git commit downloads -- Trim repetitive descriptions for size - -------------------------------------------------------------------- -Sat May 11 11:22:27 UTC 2024 - Julius Enriquez - -- Switch subpackage groups to Development/Languages/C and C++ - -------------------------------------------------------------------- -Sat May 11 11:10:50 UTC 2024 - Julius Enriquez - -- Change group to Development/Languages/C and C++ - -------------------------------------------------------------------- -Sat May 11 11:06:13 UTC 2024 - Julius Enriquez - -- Remove binary stripping - -------------------------------------------------------------------- -Sat May 11 09:27:24 UTC 2024 - Julius Enriquez - -- Add %check- - -------------------------------------------------------------------- -Sat May 11 08:57:42 UTC 2024 - Julius Enriquez - -- Disable LTO, working spec file - -------------------------------------------------------------------- -Sat May 11 08:03:53 UTC 2024 - Julius Enriquez - -- Remove tvision package, move everything except demo binaries to tvision-devel - -------------------------------------------------------------------- -Sat May 11 03:00:53 UTC 2024 - Julius Enriquez - -- Split into devel and demo subpackages - -------------------------------------------------------------------- -Fri May 10 07:13:24 UTC 2024 - Julius Enriquez - -- Replace ZIP archive with tarball +- Working spec file ------------------------------------------------------------------- Fri May 10 06:39:27 UTC 2024 - Julius Enriquez diff --git a/tvision.spec b/tvision.spec index fbd0b04..0543d5f 100644 --- a/tvision.spec +++ b/tvision.spec @@ -16,16 +16,14 @@ # -%bcond_without test Name: tvision Release: 0 -Version: 0~git630 +Version: 0~git631 Summary: Modern port of Turbo Vision 2.0 Group: Development/Languages/C and C++ License: MIT URL: https://github.com/magiblot/tvision Source: %{name}-%{version}.tar.xz -Patch1: Use-GNUInstallDirs.patch %description A modern port of Turbo Vision 2.0, the classical @@ -46,81 +44,38 @@ use and extend these; but even if you prefer creating your own, Turbo Vision already handles event dispatching, display of fullwidth Unicode characters, etc. -%package devel -Summary: Headers for Turbo Vision 2.0 -Group: Development/Languages/C and C++ -BuildRequires: binutils -BuildRequires: gcc-c++ -BuildRequires: cmake -BuildRequires: make -BuildRequires: pkgconfig(ncurses) -BuildRequires: gtest -Suggests: gpm -Suggests: (xclip or xset) - -%description devel -This package contains the headers and help file -compiler from the modernised Turbo Vision 2.0 port. - -A modern port of Turbo Vision 2.0, the classical -framework for text-based user interfaces, but with -Unicode support. - %package devel-static Summary: Static library for Turbo Vision 2.0 Group: Development/Languages/C and C++ -BuildRequires: binutils -BuildRequires: gcc-c++ +BuildRequires: c++_compiler BuildRequires: cmake -BuildRequires: make BuildRequires: pkgconfig(ncurses) BuildRequires: gtest -Suggests: gpm +BuildRequires: gpm Suggests: (xclip or xset) %description devel-static -This package contains the static library from the -modernised Turbo Vision 2.0 port. +This package contains the static library, headers, +and help file compiler from the modernised Turbo +Vision 2.0 port. A modern port of Turbo Vision 2.0, the classical framework for text-based user interfaces, but with -Unicode support. - -Turbo Vision lets application developers avoid -writing platform-specific workarounds for TUI apps. -It attempts to reproduce consistent results everywhere, -without developers worrying about terminal capabilities, -direct I/O, ifdefs, and other platform quirks. - -Turbo Vision provides many widget classes (also known -as views), including resizable, overlapping windows, -pull-down menus, dialog boxes, buttons, scroll bars, -input boxes, check boxes and radio buttons. You may -use and extend these; but even if you prefer creating -your own, Turbo Vision already handles event dispatching, -display of fullwidth Unicode characters, etc. +Unicode and cross=platform support. %package demos Summary: Demo programs of Turbo Vision 2.0 Group: Development/Languages/C and C++ -BuildRequires: binutils -BuildRequires: gcc-c++ -BuildRequires: cmake -BuildRequires: make -BuildRequires: pkgconfig(ncurses) -Requires: pkgconfig(ncurses) -Suggests: gpm Suggests: (xclip or xset) - %description demos This package contains demo programs showing off the modernised Turbo Vision 2.0 port. A modern port of Turbo Vision 2.0, the classical framework for text-based user interfaces, but -with Unicode support. +with Unicode and cross-platform support. %prep %autosetup -p1 @@ -129,7 +84,7 @@ with Unicode support. # Disable LTO due to a lto-no-text-in-archive problem with libtvision.a %global _lto_cflags %nil -# Add CMake flag to let libtvision.a be used properly as a shared lib +# Add CMake flag to let libtvision.a be used properly as a system lib %cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON %cmake_build @@ -142,15 +97,13 @@ pushd test/ %cmake_build popd -%files devel +%files devel-static %license COPYRIGHT %doc README.md %{_bindir}/tvhc %{_includedir}/* -%{_prefix}/%{_lib}/cmake/ - -%files devel-static -%{_prefix}/%{_lib}/libtvision.a +%{_libdir}/* +%{_libdir}/cmake/ %files demos %{_bindir}/tvdemo