avahi: backport CVE fixes from upstream
[feed/packages.git] / libs / libgpg-error / Makefile
1 #
2 # Copyright (C) 2005-2011 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=libgpg-error
11 PKG_VERSION:=1.47
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:=https://mirrors.dotsrc.org/gcrypt/libgpg-error \
16 http://ring.ksc.gr.jp/archives/net/gnupg/libgpg-error \
17 https://www.gnupg.org/ftp/gcrypt/libgpg-error
18 PKG_HASH:=9e3c670966b96ecc746c28c2c419541e3bcb787d1a73930f5e5f5e1bcbbb9bdb
19
20 PKG_MAINTAINER:=W. Michael Petullo <mike@flyn.org>
21 PKG_LICENSE:=LGPL-2.1-or-later
22 PKG_LICENSE_FILES:=COPYING
23 PKG_CPE_ID:=cpe:/a:gnupg:libgpg-error
24
25 PKG_FIXUP:=autoreconf
26 PKG_INSTALL:=1
27 PKG_BUILD_PARALLEL:=1
28
29 include $(INCLUDE_DIR)/package.mk
30
31 define Package/libgpg-error
32 SECTION:=libs
33 CATEGORY:=Libraries
34 TITLE:=GnuPG error handling helper library
35 URL:=https://www.gnupg.org/related_software/libgpg-error/
36 endef
37
38 define Package/libgpg-error/description
39 An helper library for common error codes and descriptions.
40 This is a library that defines common error values for all GnuPG
41 components. Among these are GPG, GPGSM, GPGME, GPG-Agent, libgcrypt,
42 Libksba, DirMngr, Pinentry, SmartCard Daemon and possibly more in the
43 future.
44 endef
45
46 CONFIGURE_ARGS += \
47 --enable-shared \
48 --enable-static \
49 --enable-install-gpg-error-config \
50 --disable-doc \
51 --disable-languages \
52 --disable-rpath \
53 --disable-tests
54
55 define Build/InstallDev
56 $(INSTALL_DIR) $(2)/bin $(1)/usr/bin
57 $(INSTALL_BIN) \
58 $(PKG_INSTALL_DIR)/usr/bin/gpg-error-config \
59 $(2)/bin/
60 $(SED) \
61 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
62 $(2)/bin/gpg-error-config
63 $(LN) $(STAGING_DIR)/host/bin/gpg-error-config $(1)/usr/bin/gpg-error-config
64
65 $(INSTALL_BIN) \
66 $(PKG_INSTALL_DIR)/usr/bin/gpgrt-config \
67 $(2)/bin/
68 $(SED) \
69 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
70 $(2)/bin/gpgrt-config
71 $(LN) $(STAGING_DIR)/host/bin/gpgrt-config $(1)/usr/bin/gpgrt-config
72
73 $(INSTALL_DIR) $(1)/usr/include
74 $(INSTALL_DATA) \
75 $(PKG_INSTALL_DIR)/usr/include/gpg-error.h \
76 $(1)/usr/include/
77
78 $(INSTALL_DATA) \
79 $(PKG_INSTALL_DIR)/usr/include/gpgrt.h \
80 $(1)/usr/include/
81
82 $(INSTALL_DIR) $(1)/usr/lib
83 $(CP) \
84 $(PKG_INSTALL_DIR)/usr/lib/libgpg-error.{la,a,so*} \
85 $(1)/usr/lib/
86
87 $(INSTALL_DIR) $(1)/usr/share/aclocal
88 $(INSTALL_DATA) \
89 $(PKG_INSTALL_DIR)/usr/share/aclocal/gpg-error.m4 \
90 $(1)/usr/share/aclocal/
91
92 $(INSTALL_DATA) \
93 $(PKG_INSTALL_DIR)/usr/share/aclocal/gpgrt.m4 \
94 $(1)/usr/share/aclocal/
95
96 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
97 $(CP) \
98 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/gpg-error.pc \
99 $(1)/usr/lib/pkgconfig
100 endef
101
102 define Package/libgpg-error/install
103 $(INSTALL_DIR) $(1)/usr/lib
104 $(CP) \
105 $(PKG_INSTALL_DIR)/usr/lib/libgpg-error.so.* \
106 $(1)/usr/lib/
107 endef
108
109 $(eval $(call BuildPackage,libgpg-error))