Merge pull request #12342 from PolynomialDivision/feature/add_dawn_node_exporter
[feed/packages.git] / libs / libxslt / Makefile
1 #
2 # Copyright (C) 2014 - 2018 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:=libxslt
11 PKG_VERSION:=1.1.34
12 PKG_RELEASE:=2
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:= \
16 http://xmlsoft.org/sources/ \
17 ftp://fr.rpmfind.net/pub/libxml/
18 PKG_HASH:=98b1bd46d6792925ad2dfe9a87452ea2adebf69dcb9919ffd55bf926a7f93f7f
19
20 PKG_MAINTAINER:=Jiri Slachta <jiri@slachta.eu>
21 PKG_LICENSE:=MIT
22 PKG_LICENSE_FILES:=COPYING
23 PKG_CPE_ID:=cpe:/a:xmlsoft:libxslt
24
25 PKG_INSTALL:=1
26 PKG_BUILD_PARALLEL:=1
27 HOST_BUILD_DEPENDS:=libxml2/host
28
29 include $(INCLUDE_DIR)/package.mk
30 include $(INCLUDE_DIR)/host-build.mk
31
32 define Package/libxslt
33 SECTION:=libs
34 CATEGORY:=Libraries
35 DEPENDS:=+libxml2
36 TITLE:=Gnome XSLT library
37 URL:=http://xmlsoft.org/XSLT/
38 endef
39
40 define Package/libxslt/description
41 A library for XML transformation using XSLT.
42 endef
43
44 define Package/libexslt
45 SECTION:=libs
46 CATEGORY:=Libraries
47 DEPENDS:=+libxslt
48 TITLE:=Gnome XSLT library Extension
49 URL:=http://xmlsoft.org/XSLT/EXSLT/
50 endef
51
52 define Package/libexslt/description
53 An extension for XSLT.
54 endef
55
56 define Package/xsltproc
57 SECTION:=utils
58 CATEGORY:=Utilities
59 DEPENDS:=+libxslt +PACKAGE_xsltproc:libexslt
60 TITLE:=Gnome XSLT xsltproc Utility
61 URL:=http://xmlsoft.org/XSLT/
62 endef
63
64 define Package/xsltproc/description
65 XSLT XML transformation utility.
66 endef
67
68 CONFIGURE_ARGS += \
69 --enable-shared \
70 --enable-static \
71 --without-python \
72 --without-crypto \
73 --without-debug \
74 --without-mem-debug \
75 --without-debugger \
76 --without-plugins
77
78 HOST_CONFIGURE_ARGS += \
79 --with-libxml-prefix=$(STAGING_DIR_HOSTPKG) \
80 --without-python \
81 --without-crypto \
82 --without-debug \
83 --without-mem-debug \
84 --without-debugger \
85 --without-profiler \
86 --without-plugins
87
88 define Build/InstallDev/Xslt
89 $(INSTALL_DIR) $(1)/usr/bin $(2)/bin $(1)/usr/include/libxslt \
90 $(1)/usr/include/libexslt $(1)/usr/lib \
91 $(1)/usr/lib/pkgconfig $(2)/share/aclocal
92
93 $(INSTALL_BIN) \
94 $(PKG_INSTALL_DIR)/usr/bin/xslt-config \
95 $(2)/bin/
96
97 ln -sf $(STAGING_DIR)/host/bin/xslt-config $(1)/usr/bin/xslt-config
98
99 $(SED) \
100 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
101 $(2)/bin/xslt-config
102
103 $(INSTALL_DATA) \
104 $(PKG_INSTALL_DIR)/usr/include/libxslt/* \
105 $(1)/usr/include/libxslt/
106
107 $(CP) \
108 $(PKG_INSTALL_DIR)/usr/lib/libxslt.{la,a,so*} \
109 $(1)/usr/lib/
110
111 $(INSTALL_DATA) \
112 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libxslt.pc \
113 $(1)/usr/lib/pkgconfig/
114
115 $(INSTALL_DATA) \
116 $(PKG_INSTALL_DIR)/usr/share/aclocal/* \
117 $(2)/share/aclocal
118 endef
119
120 define Build/InstallDev/Exslt
121 $(INSTALL_DIR) $(1)/usr/include/libexslt $(1)/usr/lib/pkgconfig
122 $(INSTALL_DATA) \
123 $(PKG_INSTALL_DIR)/usr/include/libexslt/* \
124 $(1)/usr/include/libexslt/
125
126 $(CP) \
127 $(PKG_INSTALL_DIR)/usr/lib/libexslt.{la,a,so*} \
128 $(1)/usr/lib/
129
130 $(INSTALL_DATA) \
131 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libexslt.pc \
132 $(1)/usr/lib/pkgconfig/
133 endef
134
135 define Build/InstallDev
136 $(if $(CONFIG_PACKAGE_libxslt),$(call Build/InstallDev/Xslt,$(1),$(2)))
137 $(if $(CONFIG_PACKAGE_libexslt),$(call Build/InstallDev/Exslt,$(1),$(2)))
138 endef
139
140 define Package/libxslt/install
141 $(INSTALL_DIR) $(1)/usr/lib
142 $(CP) \
143 $(PKG_INSTALL_DIR)/usr/lib/libxslt.so* \
144 $(1)/usr/lib/
145 endef
146
147 define Package/libexslt/install
148 $(INSTALL_DIR) $(1)/usr/lib
149 $(CP) \
150 $(PKG_INSTALL_DIR)/usr/lib/libexslt.so* \
151 $(1)/usr/lib/
152 endef
153
154 define Package/xsltproc/install
155 $(INSTALL_DIR) $(1)/usr/bin
156 $(INSTALL_BIN) \
157 $(PKG_INSTALL_DIR)/usr/bin/xsltproc \
158 $(1)/usr/bin/
159 endef
160
161 $(eval $(call BuildPackage,libxslt))
162 $(eval $(call BuildPackage,libexslt))
163 $(eval $(call BuildPackage,xsltproc))
164 $(eval $(call HostBuild))