From 9812d91e44b2df73e86ec0d5821dbf0fd1076144 Mon Sep 17 00:00:00 2001 From: Siteshwar Vashisht Date: Jan 17 2022 20:28:27 +0000 Subject: Add pkg-config configurations for libhistory Resolves: #2026123 --- diff --git a/0001-Add-pkg-config-configurations-for-libhistory.patch b/0001-Add-pkg-config-configurations-for-libhistory.patch new file mode 100644 index 0000000..86e3a17 --- /dev/null +++ b/0001-Add-pkg-config-configurations-for-libhistory.patch @@ -0,0 +1,117 @@ +From 5ad621bce2ec28f97706e58979b328f98367fd3f Mon Sep 17 00:00:00 2001 +From: Siteshwar Vashisht +Date: Mon, 17 Jan 2022 21:27:26 +0100 +Subject: [PATCH] Add pkg-config configurations for libhistory + +--- + MANIFEST | 1 + + Makefile.in | 8 ++++++-- + configure | 3 ++- + configure.ac | 2 +- + history.pc.in | 12 ++++++++++++ + 5 files changed, 22 insertions(+), 4 deletions(-) + create mode 100644 history.pc.in + +diff --git a/MANIFEST b/MANIFEST +index ad49d66..5da0afa 100644 +--- a/MANIFEST ++++ b/MANIFEST +@@ -21,6 +21,7 @@ configure f + configure.ac f + Makefile.in f + readline.pc.in f ++history.pc.in f + ansi_stdlib.h f + chardefs.h f + colors.h f +diff --git a/Makefile.in b/Makefile.in +index c57db60..2120daa 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -149,7 +149,7 @@ DOCUMENTATION = $(DOCSOURCE) $(DOCOBJECT) $(DOCSUPPORT) + + CREATED_MAKEFILES = Makefile doc/Makefile examples/Makefile shlib/Makefile + CREATED_CONFIGURE = config.status config.h config.cache config.log \ +- stamp-config stamp-h readline.pc ++ stamp-config stamp-h readline.pc history.pc + CREATED_TAGS = TAGS tags + + INSTALLED_HEADERS = readline.h chardefs.h keymaps.h history.h tilde.h \ +@@ -243,10 +243,11 @@ maybe-uninstall-headers: uninstall-headers + + install-pc: installdirs + -$(INSTALL_DATA) $(BUILD_DIR)/readline.pc $(DESTDIR)$(pkgconfigdir)/readline.pc ++ -$(INSTALL_DATA) $(BUILD_DIR)/history.pc $(DESTDIR)$(pkgconfigdir)/history.pc + + uninstall-pc: + -test -n "$(pkgconfigdir)" && cd $(DESTDIR)$(pkgconfigdir) && \ +- ${RM} readline.pc ++ ${RM} readline.pc history.pc + + maybe-uninstall-pc: uninstall-pc + +@@ -324,6 +325,9 @@ distclean maintainer-clean: clean + readline.pc: config.status $(srcdir)/readline.pc.in + $(SHELL) config.status + ++history.pc: config.status $(srcdir)/history.pc.in ++ $(SHELL) config.status ++ + info dvi html pdf ps: + -( cd doc && $(MAKE) $(MFLAGS) $@ ) + +diff --git a/configure b/configure +index 5a0bf2f..fe5d4b4 100755 +--- a/configure ++++ b/configure +@@ -6941,7 +6941,7 @@ CFLAGS="$CFLAGS $STYLE_CFLAGS" + + + +-ac_config_files="$ac_config_files Makefile doc/Makefile examples/Makefile shlib/Makefile readline.pc" ++ac_config_files="$ac_config_files Makefile doc/Makefile examples/Makefile shlib/Makefile readline.pc history.pc" + + ac_config_commands="$ac_config_commands default" + +@@ -7645,6 +7645,7 @@ do + "examples/Makefile") CONFIG_FILES="$CONFIG_FILES examples/Makefile" ;; + "shlib/Makefile") CONFIG_FILES="$CONFIG_FILES shlib/Makefile" ;; + "readline.pc") CONFIG_FILES="$CONFIG_FILES readline.pc" ;; ++ "history.pc") CONFIG_FILES="$CONFIG_FILES history.pc" ;; + "default") CONFIG_COMMANDS="$CONFIG_COMMANDS default" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; +diff --git a/configure.ac b/configure.ac +index 147bae5..070c891 100644 +--- a/configure.ac ++++ b/configure.ac +@@ -328,7 +328,7 @@ AC_SUBST(LIBVERSION) + AC_SUBST(TERMCAP_LIB) + AC_SUBST(TERMCAP_PKG_CONFIG_LIB) + +-AC_OUTPUT([Makefile doc/Makefile examples/Makefile shlib/Makefile readline.pc], ++AC_OUTPUT([Makefile doc/Makefile examples/Makefile shlib/Makefile readline.pc history.pc], + [ + # Makefile uses this timestamp file to record whether config.h is up to date. + echo > stamp-h +diff --git a/history.pc.in b/history.pc.in +new file mode 100644 +index 0000000..aa4a0c9 +--- /dev/null ++++ b/history.pc.in +@@ -0,0 +1,12 @@ ++prefix=@prefix@ ++exec_prefix=@exec_prefix@ ++libdir=@libdir@ ++includedir=@includedir@ ++ ++Name: History ++Description: Gnu History library for managing the text of previously typed lines ++URL: http://tiswww.cwru.edu/php/chet/readline/rltop.html ++Version: @LIBVERSION@ ++Requires.private: @TERMCAP_PKG_CONFIG_LIB@ ++Libs: -L${libdir} -lhistory ++Cflags: -I${includedir} +-- +2.31.1 + diff --git a/readline.spec b/readline.spec index 7ae8836..cb942aa 100644 --- a/readline.spec +++ b/readline.spec @@ -1,7 +1,7 @@ Summary: A library for editing typed command lines Name: readline Version: 8.1 -Release: 4%{?dist} +Release: 5%{?dist} License: GPLv3+ URL: https://tiswww.case.edu/php/chet/readline/rltop.html Source: ftp://ftp.gnu.org/gnu/readline/readline-%{version}.tar.gz @@ -14,6 +14,9 @@ Patch2: readline-8.1-patch-2.patch # Other patches # Remove RPATH, use CFLAGS Patch101: readline-8.0-shlib.patch +# Remove this patch during next rebase +# https://git.savannah.gnu.org/cgit/readline.git/commit/?h=devel&id=d5d497730cf7708b6dcb85479f8bdfc748d23ff8 +Patch102: 0001-Add-pkg-config-configurations-for-libhistory.patch BuildRequires: make BuildRequires: gcc @@ -74,6 +77,7 @@ rm -vf %{buildroot}%{_infodir}/dir* %{_libdir}/libreadline.so %{_libdir}/libhistory.so %{_libdir}/pkgconfig/%{name}.pc +%{_libdir}/pkgconfig/history.pc %{_mandir}/man3/readline.3* %{_mandir}/man3/history.3* %{_infodir}/readline.info* @@ -83,6 +87,10 @@ rm -vf %{buildroot}%{_infodir}/dir* %{_libdir}/libhistory.a %changelog +* Mon Jan 17 2022 Siteshwar Vashisht - 8.1-5 +- Add pkg-config configurations for libhistory + Resolves: #2026123 + * Mon Jan 17 2022 Siteshwar Vashisht - 8.1-4 - Update to readline-8.1 patchlevel 2 Resolves: #2037430