diff options
author | Anas Nashif <anas.nashif@intel.com> | 2012-11-07 09:24:27 -0800 |
---|---|---|
committer | Piotr Sawicki <p.sawicki2@partner.samsung.com> | 2017-11-06 08:53:44 +0100 |
commit | 5314683478906f19d78c4c21f7d163ba96e15dc6 (patch) | |
tree | 6e36a1400617a71e106fc716cb471a7efc47b037 | |
parent | 44429cce0568beb59b87fafcf649f00bd4bac5a4 (diff) | |
download | libgpg-error-5314683478906f19d78c4c21f7d163ba96e15dc6.tar.gz libgpg-error-5314683478906f19d78c4c21f7d163ba96e15dc6.tar.bz2 libgpg-error-5314683478906f19d78c4c21f7d163ba96e15dc6.zip |
add packaging
-rw-r--r-- | packaging/baselibs.conf | 6 | ||||
-rw-r--r-- | packaging/libgpg-error-nld-build.diff | 88 | ||||
-rw-r--r-- | packaging/libgpg-error.spec | 79 |
3 files changed, 173 insertions, 0 deletions
diff --git a/packaging/baselibs.conf b/packaging/baselibs.conf new file mode 100644 index 0000000..4407831 --- /dev/null +++ b/packaging/baselibs.conf @@ -0,0 +1,6 @@ +libgpg-error0 + obsoletes "libgpg-error-<targettype> <= <version>" + provides "libgpg-error-<targettype> = <version>" +libgpg-error-devel + requires -libgpg-error-<targettype> + requires "libgpg-error0-<targettype> = <version>" diff --git a/packaging/libgpg-error-nld-build.diff b/packaging/libgpg-error-nld-build.diff new file mode 100644 index 0000000..19a5f48 --- /dev/null +++ b/packaging/libgpg-error-nld-build.diff @@ -0,0 +1,88 @@ +--- po/Makevars ++++ po/Makevars 2004/07/14 08:56:43 +@@ -1,7 +1,7 @@ + # Makefile variables for PO directory in any package using GNU gettext. + + # Usually the message domain is the same as the package name. +-DOMAIN = $(PACKAGE) ++DOMAIN = $(PACKAGE)-nld + + # These two variables depend on the location of this directory. + subdir = po +--- src/gpg-error-config.in ++++ src/gpg-error-config.in 2004/07/14 08:57:04 +@@ -65,7 +65,7 @@ + if test "x$libdir" != "x/usr/lib" -a "x$libdir" != "x/lib"; then + output="$output -L$libdir" + fi +- output="$output -lgpg-error" ++ output="$output -lgpg-error-nld" + ;; + *) + usage 1 1>&2 +--- src/Makefile.am ++++ src/Makefile.am 2004/07/14 08:56:43 +@@ -37,19 +37,19 @@ + + include_HEADERS = gpg-error.h + +-lib_LTLIBRARIES = libgpg-error.la ++lib_LTLIBRARIES = libgpg-error-nld.la + +-libgpg_error_la_LDFLAGS = -version-info \ ++libgpg_error_nld_la_LDFLAGS = -version-info \ + @LIBGPG_ERROR_LT_CURRENT@:@LIBGPG_ERROR_LT_REVISION@:@LIBGPG_ERROR_LT_AGE@ + +-libgpg_error_la_SOURCES = gpg-error.h gettext.h \ ++libgpg_error_nld_la_SOURCES = gpg-error.h gettext.h \ + strsource.c strerror.c code-to-errno.c code-from-errno.c + +-libgpg_error_la_LIBADD = @LTLIBINTL@ ++libgpg_error_nld_la_LIBADD = @LTLIBINTL@ + + bin_PROGRAMS = gpg-error + gpg_error_SOURCES = strsource-sym.c strerror-sym.c gpg-error.c +-gpg_error_LDADD = ./libgpg-error.la ++gpg_error_LDADD = ./libgpg-error-nld.la + + err-sources.h: Makefile mkstrtable.awk err-sources.h.in + $(AWK) -f $(srcdir)/mkstrtable.awk -v textidx=3 \ +--- src/strerror.c ++++ src/strerror.c 2004/07/14 08:56:43 +@@ -47,7 +47,7 @@ + else + code = GPG_ERR_UNKNOWN_ERRNO; + } +- return dgettext (PACKAGE, msgstr + msgidx[msgidxof (code)]); ++ return dgettext (PACKAGE"-nld", msgstr + msgidx[msgidxof (code)]); + } + + +@@ -158,7 +158,7 @@ + code = GPG_ERR_UNKNOWN_ERRNO; + } + +- errstr = dgettext (PACKAGE, msgstr + msgidx[msgidxof (code)]); ++ errstr = dgettext (PACKAGE"-nld", msgstr + msgidx[msgidxof (code)]); + errstr_len = strlen (errstr) + 1; + cpy_len = errstr_len < buflen ? errstr_len : buflen; + memcpy (buf, errstr, cpy_len); +--- src/strsource.c ++++ src/strsource.c 2004/07/14 08:56:43 +@@ -33,5 +33,5 @@ + gpg_strsource (gpg_error_t err) + { + gpg_err_source_t source = gpg_err_source (err); +- return dgettext (PACKAGE, msgstr + msgidx[msgidxof (source)]); ++ return dgettext (PACKAGE"-nld", msgstr + msgidx[msgidxof (source)]); + } +--- tests/Makefile.am ++++ tests/Makefile.am 2004/07/14 08:56:43 +@@ -23,6 +23,6 @@ + + INCLUDES = -I$(top_builddir)/src + +-LDADD = ../src/libgpg-error.la ++LDADD = ../src/libgpg-error-nld.la + + noinst_PROGRAMS = $(TESTS) diff --git a/packaging/libgpg-error.spec b/packaging/libgpg-error.spec new file mode 100644 index 0000000..aa6b582 --- /dev/null +++ b/packaging/libgpg-error.spec @@ -0,0 +1,79 @@ +# +# spec file for package libgpg-error +# +# Copyright (c) 2012 SUSE LINUX Products GmbH, Nuernberg, Germany. +# +# 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 http://bugs.opensuse.org/ +# + + +Name: libgpg-error +Version: 1.10 +Release: 0 +License: GPL-2.0+ ; LGPL-2.1+ +Summary: Library That Defines Common Error Values for All GnuPG Components +Url: http://www.gnupg.org/ +Group: Development/Libraries/C and C++ +Source: %{name}-%{version}.tar.bz2 +Source2: baselibs.conf +Patch0: %{name}-nld-build.diff +BuildRequires: gettext-tools +BuildRequires: libtool +BuildRoot: %{_tmppath}/%{name}-%{version}-build + +%description +This is a library that defines common error values for all GnuPG +components. Among these are GPG, GPGSM, GPGME, GPG-Agent, libgcrypt, +pinentry, SmartCard Daemon, and possibly more in the future. + +%package devel +License: GPL-2.0+ ; LGPL-2.1+ ; MIT +Summary: Development package for libgpg-error +Group: Development/Libraries/C and C++ +Requires: glibc-devel +Requires: libgpg-error = %{version} + +%description devel +Files needed for software development using libgpg-error. + +%prep +%setup -q -n libgpg-error-%{version} + +%build +autoreconf -fiv +%configure --disable-static --with-pic +make %{?_smp_mflags} + +%install +%make_install +# Drop the lisp stuff, it depends on ASDF and CFFI +# which needs to be packaged first +rm -r %{buildroot}%{_datadir}/common-lisp +%find_lang %{name} + +%post -p /sbin/ldconfig + +%postun -p /sbin/ldconfig + +%files -f %{name}.lang +%defattr(-,root,root) +%{_libdir}/libgpg-error*.so.* + +%files devel +%defattr(-,root,root) +%doc README NEWS ChangeLog COPYING.LIB COPYING AUTHORS ABOUT-NLS +%{_datadir}/aclocal/gpg-error.m4 +%{_includedir}/* +%{_bindir}/* +%{_libdir}/libgpg-error*.so + +%changelog |