From e073a0952f2382fb553656c9423c6c23f1c8bc37 Mon Sep 17 00:00:00 2001 From: Raven Date: Fri, 15 Mar 2024 17:48:07 +0600 Subject: [PATCH] libassuan: import patch to create pkgconfig files --- libassuan/libassuan-2.1.0-multilib.patch | 28 +++ libassuan/libassuan-port-pkgconfig.patch | 142 +++++++++++ libassuan/libassuan.spec | 295 +++++++++++++++++++++++ 3 files changed, 465 insertions(+) create mode 100644 libassuan/libassuan-2.1.0-multilib.patch create mode 100644 libassuan/libassuan-port-pkgconfig.patch create mode 100644 libassuan/libassuan.spec diff --git a/libassuan/libassuan-2.1.0-multilib.patch b/libassuan/libassuan-2.1.0-multilib.patch new file mode 100644 index 0000000..f6ec6aa --- /dev/null +++ b/libassuan/libassuan-2.1.0-multilib.patch @@ -0,0 +1,28 @@ +diff -up libassuan-2.1.0/src/libassuan-config.in.multilib libassuan-2.1.0/src/libassuan-config.in +--- libassuan-2.1.0/src/libassuan-config.in.multilib 2013-05-15 12:41:33.376279564 +0200 ++++ libassuan-2.1.0/src/libassuan-config.in 2013-05-15 12:40:11.565515616 +0200 +@@ -18,7 +18,7 @@ lib="@LIBASSUAN_CONFIG_LIB@" + extralibs="@LIBASSUAN_CONFIG_EXTRA_LIBS@ $gpg_error_libs" + cflags="@LIBASSUAN_CONFIG_CFLAGS@ $gpg_error_cflags" + api_version="@LIBASSUAN_CONFIG_API_VERSION@" +-my_host="@LIBASSUAN_CONFIG_HOST@" ++my_host="none" + prefix=@prefix@ + exec_prefix=@exec_prefix@ + includes="" +@@ -121,13 +121,7 @@ if test "$echo_cflags" = "yes"; then + fi + + if test "$echo_libs" = "yes"; then +- if test "@libdir@" != "/usr/lib" ; then +- libdirs="-L@libdir@" +- for i in $lib $extralibs ; do +- if test "$i" = "-L@libdir@" ; then +- libdirs="" +- fi +- done +- fi ++ # libdir is always standard and implicitly searched ++ libdirs="" + echo $libdirs $lib $extralibs + fi diff --git a/libassuan/libassuan-port-pkgconfig.patch b/libassuan/libassuan-port-pkgconfig.patch new file mode 100644 index 0000000..9c67a64 --- /dev/null +++ b/libassuan/libassuan-port-pkgconfig.patch @@ -0,0 +1,142 @@ +diff -Naur a/configure b/configure +--- a/configure 2017-12-07 20:55:50.000000000 +0600 ++++ b/configure 2024-03-15 16:51:27.191259824 +0600 +@@ -14801,6 +14801,8 @@ + + ac_config_files="$ac_config_files src/versioninfo.rc" + ++ac_config_files="$ac_config_files src/libassuan.pc" ++ + + cat >confcache <<\_ACEOF + # This file is a shell script that caches the results of configure +@@ -15921,6 +15923,7 @@ + "tests/Makefile") CONFIG_FILES="$CONFIG_FILES tests/Makefile" ;; + "src/libassuan-config") CONFIG_FILES="$CONFIG_FILES src/libassuan-config" ;; + "src/versioninfo.rc") CONFIG_FILES="$CONFIG_FILES src/versioninfo.rc" ;; ++ "src/libassuan.pc") CONFIG_FILES="$CONFIG_FILES src/libassuan.pc" ;; + + *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; + esac +diff -Naur a/configure.ac b/configure.ac +--- a/configure.ac 2017-12-07 20:53:45.000000000 +0600 ++++ b/configure.ac 2024-03-15 17:09:36.553206721 +0600 +@@ -73,9 +73,6 @@ + AC_SUBST(LIBASSUAN_LT_AGE) + AC_SUBST(LIBASSUAN_LT_REVISION) + +-PACKAGE=$PACKAGE_NAME +-VERSION=$PACKAGE_VERSION +- + AC_CONFIG_AUX_DIR([build-aux]) + AM_INIT_AUTOMAKE([serial-tests dist-bzip2 no-dist-gzip]) + AM_MAINTAINER_MODE +@@ -88,12 +85,6 @@ + + AC_GNU_SOURCE + +- +-AC_SUBST(PACKAGE) +-AC_SUBST(VERSION) +-AC_DEFINE_UNQUOTED(PACKAGE, "$PACKAGE", [Name of this package]) +-AC_DEFINE_UNQUOTED(VERSION, "$VERSION", [Version of this package]) +-AC_DEFINE_UNQUOTED(PACKAGE_BUGREPORT, "$PACKAGE_BUGREPORT",[Bug report address]) + VERSION_NUMBER=m4_esyscmd(printf "0x%02x%02x%02x" mym4_major \ + mym4_minor mym4_micro) + AC_SUBST(VERSION_NUMBER) +@@ -485,6 +476,7 @@ + AC_CONFIG_FILES([tests/Makefile]) + AC_CONFIG_FILES([src/libassuan-config], [chmod +x src/libassuan-config]) + AC_CONFIG_FILES([src/versioninfo.rc]) ++AC_CONFIG_FILES([src/libassuan.pc]) + + AC_OUTPUT + +diff -Naur a/libassuan.pc.in b/libassuan.pc.in +--- a/src/libassuan.pc.in 1970-01-01 06:00:00.000000000 +0600 ++++ b/scr/libassuan.pc.in 2024-03-15 16:47:41.398721127 +0600 +@@ -0,0 +1,15 @@ ++prefix=@prefix@ ++exec_prefix=@exec_prefix@ ++includedir=@includedir@ ++libdir=@libdir@ ++host=@LIBASSUAN_CONFIG_HOST@ ++api_version=@LIBASSUAN_CONFIG_API_VERSION@ ++ ++Name: libassuan ++Description: IPC library for the GnuPG components ++Requires.private: gpg-error ++Version: @PACKAGE_VERSION@ ++Cflags: -I${includedir} @LIBASSUAN_CONFIG_CFLAGS@ ++Libs: -L${libdir} @LIBASSUAN_CONFIG_LIBS@ ++Libs.private: @NETLIBS@ ++URL: https://www.gnupg.org/related_software/libassuan/index.html +diff -Naur a/src/libassuan-config.in b/src/libassuan-config.in +--- a/src/libassuan-config.in 2017-11-15 21:52:31.000000000 +0600 ++++ b/src/libassuan-config.in 2024-03-15 17:13:47.121583049 +0600 +@@ -70,7 +70,16 @@ + --exec-prefix) + echo_exec_prefix=yes + ;; +- --version) ++ --variable=*) ++ case "${1#*=}" in ++ prefix) echo "$prefix" ;; ++ exec_prefix) echo "$exec_prefix" ;; ++ host) echo "$my_host" ;; ++ api_version) echo "$api_version" ;; ++ esac ++ exit 0 ++ ;; ++ --modversion|--version) + echo "@VERSION@" + exit 0 + ;; +diff -Naur a/src/Makefile.am b/src/Makefile.am +--- a/src/Makefile.am 2017-11-15 21:31:49.000000000 +0600 ++++ b/src/Makefile.am 2024-03-15 17:08:47.061527425 +0600 +@@ -19,8 +19,12 @@ + # SPDX-License-Identifier: LGPL-2.1+ + ## Process this file with automake to produce Makefile.in + ++pkgconfigdir = $(libdir)/pkgconfig ++pkgconfig_DATA = libassuan.pc ++ + EXTRA_DIST = libassuan-config.in libassuan.m4 libassuan.vers \ +- versioninfo.rc.in libassuan.def mkheader.c gpgcedev.def ++ versioninfo.rc.in libassuan.def mkheader.c gpgcedev.def \ ++ libassuan.pc.in + AM_CPPFLAGS = -I.. + + bin_SCRIPTS = libassuan-config +diff -Naur a/src/Makefile.in b/src/Makefile.in +--- a/src/Makefile.in 2017-12-07 20:55:49.000000000 +0600 ++++ b/src/Makefile.in 2024-03-15 17:01:20.349420974 +0600 +@@ -111,7 +111,7 @@ + DIST_COMMON = $(srcdir)/Makefile.in $(srcdir)/Makefile.am \ + $(srcdir)/libassuan-config.in $(srcdir)/versioninfo.rc.in \ + setenv.c funopen.c isascii.c stpcpy.c putc_unlocked.c \ +- memrchr.c $(top_srcdir)/build-aux/depcomp ++ memrchr.c $(top_srcdir)/build-aux/depcomp $(srcdir)/libassuan.pc.in + ACLOCAL_M4 = $(top_srcdir)/aclocal.m4 + am__aclocal_m4_deps = $(top_srcdir)/m4/autobuild.m4 \ + $(top_srcdir)/m4/gpg-error.m4 $(top_srcdir)/m4/libtool.m4 \ +@@ -123,7 +123,7 @@ + $(ACLOCAL_M4) + mkinstalldirs = $(install_sh) -d + CONFIG_HEADER = $(top_builddir)/config.h +-CONFIG_CLEAN_FILES = libassuan-config versioninfo.rc ++CONFIG_CLEAN_FILES = libassuan-config versioninfo.rc libassuan.pc + CONFIG_CLEAN_VPATH_FILES = + am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; + am__vpath_adj = case $$p in \ +@@ -416,7 +416,8 @@ + top_builddir = @top_builddir@ + top_srcdir = @top_srcdir@ + EXTRA_DIST = libassuan-config.in libassuan.m4 libassuan.vers \ +- versioninfo.rc.in libassuan.def mkheader.c gpgcedev.def ++ versioninfo.rc.in libassuan.def mkheader.c gpgcedev.def \ ++ libassuan.pc.in + + AM_CPPFLAGS = -I.. + bin_SCRIPTS = libassuan-config diff --git a/libassuan/libassuan.spec b/libassuan/libassuan.spec new file mode 100644 index 0000000..8cc3a4a --- /dev/null +++ b/libassuan/libassuan.spec @@ -0,0 +1,295 @@ +Name: libassuan +Summary: GnuPG IPC library +Version: 2.5.1 +Release: 10%{?dist} + +# The library is LGPLv2+, the documentation GPLv3+ +License: LGPLv2+ and GPLv3+ +Source0: https://gnupg.org/ftp/gcrypt/libassuan/libassuan-%{version}.tar.bz2 +Source1: https://gnupg.org/ftp/gcrypt/libassuan/libassuan-%{version}.tar.bz2.sig +URL: http://www.gnupg.org/ + +Patch0: libassuan-port-pkgconfig.patch +Patch1: libassuan-2.1.0-multilib.patch + + +BuildRequires: gawk pkgconfig +BuildRequires: libgpg-error-devel >= 1.8 + +%description +This is the IPC library used by GnuPG 2, GPGME and a few other +packages. + +%package devel +Summary: GnuPG IPC library +Provides: libassuan2-devel = %{version}-%{release} +Provides: libassuan2-devel%{?_isa} = %{version}-%{release} +Requires: %{name}%{?_isa} = %{version}-%{release} +Requires(post): /sbin/install-info +Requires(preun): /sbin/install-info +%description devel +This is the IPC static library used by GnuPG 2, GPGME and a few other +packages. + +This package contains files needed to develop applications using %{name}. + + +%prep +%setup -q + +%patch0 -p1 -b .pkgconfig +%patch1 -p1 -b .multilib + + +%build +%configure \ + --includedir=%{_includedir}/libassuan2 + +%make_build + + +%install +%make_install + +mkdir -p %{buildroot}%{_libdir}/pkgconfig +install -m644 src/libassuan.pc %{buildroot}%{_libdir}/pkgconfig/libassuan.pc + +## Unpackaged files +rm -fv %{buildroot}%{_infodir}/dir +rm -fv %{buildroot}%{_libdir}/lib*.la + + +%check +make check + + +%ldconfig_scriptlets + +%post devel +/sbin/install-info %{_infodir}/assuan.info %{_infodir}/dir &>/dev/null || : + +%preun devel +if [ $1 -eq 0 ]; then + /sbin/install-info --delete %{_infodir}/assuan.info %{_infodir}/dir &>/dev/null || : +fi + + +%files +%license COPYING COPYING.LIB +%doc AUTHORS ChangeLog NEWS README THANKS TODO +%{_libdir}/libassuan.so.0* + +%files devel +%{_bindir}/libassuan-config +%{_includedir}/libassuan2/ +%{_libdir}/libassuan.so +%{_libdir}/pkgconfig/libassuan.pc +%{_datadir}/aclocal/libassuan.m4 +%{_infodir}/assuan.info* + + +%changelog +* Fri Mar 15 2024 Raven -2.5.1-10 +- import patch for pkgconfig compatibility + +* Wed Feb 07 2018 Fedora Release Engineering - 2.5.1-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild + +* Sat Feb 03 2018 Igor Gnatenko - 2.5.1-2 +- Switch to %%ldconfig_scriptlets + +* Fri Dec 08 2017 Tomáš Mráz 2.5.1-1 +- new upstream release 2.5.1 + +* Fri Nov 24 2017 Tomáš Mráz 2.4.4-1 +- new upstream release 2.4.4 + +* Mon Aug 07 2017 Rex Dieter - 2.4.3-6 +- .spec cosmetics, update source URLs + +* Mon Aug 07 2017 Igor Gnatenko - 2.4.3-5 +- Drop unneeded pth-devel dependencies + +* Thu Aug 03 2017 Fedora Release Engineering - 2.4.3-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild + +* Wed Jul 26 2017 Fedora Release Engineering - 2.4.3-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild + +* Fri Feb 10 2017 Fedora Release Engineering - 2.4.3-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild + +* Thu Jul 14 2016 Tomáš Mráz 2.4.3-1 +- new upstream release + +* Thu Feb 04 2016 Fedora Release Engineering - 2.4.2-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + +* Thu Dec 3 2015 Tomáš Mráz 2.4.2-1 +- new upstream release + +* Tue Nov 24 2015 Tomáš Mráz 2.4.1-1 +- new upstream release + +* Wed Sep 2 2015 Tomáš Mráz 2.3.0-1 +- new upstream release + +* Wed Jun 17 2015 Fedora Release Engineering - 2.2.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + +* Fri Dec 19 2014 Tomáš Mráz 2.2.0-1 +- new upstream release + +* Thu Sep 11 2014 Tomáš Mráz 2.1.2-1 +- new upstream release + +* Sun Aug 17 2014 Fedora Release Engineering - 2.1.0-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + +* Thu Jul 17 2014 Tom Callaway - 2.1.0-4 +- fix license handling + +* Sat Jun 07 2014 Fedora Release Engineering - 2.1.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + +* Sat Aug 03 2013 Fedora Release Engineering - 2.1.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + +* Wed May 15 2013 Tomáš Mráz 2.1.0-1 +- new upstream release + +* Thu Feb 14 2013 Fedora Release Engineering - 2.0.3-5 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild + +* Mon Dec 3 2012 Tomáš Mráz 2.0.3-4 +- multilib conflict in libassuan-config fixed + +* Thu Jul 19 2012 Fedora Release Engineering - 2.0.3-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild + +* Thu Apr 19 2012 Tomáš Mráz 2.0.3-2 +- add missing requires of base package + +* Wed Apr 18 2012 Tomáš Mráz 2.0.3-1 +- new upstream release + +* Fri Jan 13 2012 Fedora Release Engineering - 2.0.1-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild + +* Fri Jul 15 2011 Tomáš Mráz 2.0.1-1 +- new upstream release + +* Thu Apr 14 2011 Rex Dieter 2.0.0-4 +- Missing ldconfig calls (#696787) + +* Mon Feb 07 2011 Fedora Release Engineering - 2.0.0-3 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild + +* Tue Aug 10 2010 Rex Dieter - 2.0.0-2 +- -devel: Provides: libassuan2-devel + +* Tue Jul 27 2010 Rex Dieter - 2.0.0-1 +- libassuan-2.0.0 (#573796) + +* Thu Dec 17 2009 Rex Dieter - 1.0.5-4 +- better versioning for Obsoletes +- better (upstreamable) multilib patch + +* Thu Dec 17 2009 Tomas Mraz - 1.0.5-3 +- Fix license tag - the documentation is GPLv3+ + +* Fri Jul 24 2009 Fedora Release Engineering - 1.0.5-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild + +* Sat Jun 20 2009 Rex Dieter - 1.0.5-1 +- libassuan-1.0.5 + +* Wed Feb 25 2009 Fedora Release Engineering - 1.0.4-4 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild + +* Thu Apr 03 2008 Rex Dieter 1.0.4-3 +- multiarch conflicts (#341911) + +* Fri Feb 08 2008 Rex Dieter 1.0.4-2 +- respin (gcc43) + +* Wed Dec 12 2007 Rex Dieter - 1.0.4-1 +- libassuan-1.0.4 +- License: LGPLv2+ +- disable useless -debuginfo (static libs only) + +* Sun Aug 26 2007 Rex Dieter - 1.0.3-2 +- BR: gawk (to reenable pth support) + +* Fri Aug 24 2007 Rex Dieter - 1.0.3-1 +- libassuan-1.0.3 +- License: LGPLv2 + +* Thu Aug 02 2007 Rex Dieter - 1.0.2-2 +- License: LGPLv3 (clarification, changed from LGPLv2 1.0.1 -> 1.0.2) + +* Fri Jul 06 2007 Rex Dieter - 1.0.2-1 +- libassuan-1.0.2 +- rename -static -> -devel + +* Sat Nov 25 2006 Rex Dieter - 1.0.1-1 +- libassuan-1.0.1 + +* Mon Nov 13 2006 Rex Dieter - 1.0.0-1 +- libassuan-1.0.0 +- rename -devel -> -static (+Obsoletes/Provides: %%name-devel) + +* Wed Oct 18 2006 Rex Dieter - 0.9.3-2 +- another libassuan.m4 patch + +* Tue Oct 10 2006 Rex Dieter - 0.9.3-1 +- 0.9.3 +- BR: pth-devel, -devel: Requires: pth-devel + +* Wed Oct 04 2006 Rex Dieter - 0.9.2-1 +- 0.9.2 + +* Mon Oct 02 2006 Rex Dieter - 0.9.0-3 +- respin + +* Tue Sep 26 2006 Rex Dieter - 0.6.10-3 +- fc6 respin + +* Wed Mar 1 2006 Rex Dieter +- fc5: gcc/glibc respin + +* Mon Jul 4 2005 Michael Schwendt - 0.6.10-2 +- Build PIC only for x86_64. + +* Fri Jul 1 2005 Ville Skyttä - 0.6.10-1 +- 0.6.10, macro patch no longer needed (#162262). + +* Sun May 8 2005 Michael Schwendt - 0.6.9-4 +- rebuilt + +* Fri Mar 18 2005 Ville Skyttä - 0.6.9-3 +- Fix FC4 build and source URLs. + +* Thu Feb 3 2005 Michael Schwendt - 0.6.9-2 +- Build PIC to fix x86_64 linking. + +* Thu Jan 06 2005 Rex Dieter - 0.6.9-1 +- 0.6.9 + +* Sat Oct 23 2004 Rex Dieter - 0.6.7-0.fdr.3 +- *really* fix description this time. + +* Fri Oct 22 2004 Rex Dieter - 0.6.7-0.fdr.2 +- remove "We decided..." part of description +- remove hard-coded .gz info references +- Req(preun)->Preq(postun): /sbin/install-info + +* Thu Oct 21 2004 Rex Dieter - 0.6.7-0.fdr.1 +- cleanup, make presentable. + +* Tue Oct 19 2004 Rex Dieter - 0.6.7-0.fdr.0 +- first try