2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
15 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
16 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
17 PKG_SOURCE_URL
:=http
://xmlsoft.org
/sources
/ \
18 ftp
://fr.rpmfind.net
/pub
/libxml
/
19 PKG_MD5SUM
:=db71660bb7d01ccd4e6be990af8d813b
22 PKG_INSTALL_DIR
:=$(PKG_BUILD_DIR
)/ipkg-install
24 include $(INCLUDE_DIR
)/package.mk
26 define Package
/libxslt
30 TITLE
:=Gnome XSLT library
31 DESCRIPTION
:=A library for XML transformation using XSLT.
32 URL
:=http
://xmlsoft.org
/XSLT
/
35 define Build
/Configure
36 (cd
$(PKG_BUILD_DIR
); rm -f config.cache
; \
37 $(TARGET_CONFIGURE_OPTS
) \
38 CFLAGS
="$(strip $(TARGET_CFLAGS))" \
39 CPPFLAGS
="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include -I$(STAGING_DIR)/usr/include/libxml2" \
40 LDFLAGS
="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
42 --target
=$(GNU_TARGET_NAME
) \
43 --host
=$(GNU_TARGET_NAME
) \
44 --build
=$(GNU_HOST_NAME
) \
50 --datadir=/usr
/share \
51 --includedir=/usr
/include \
52 --infodir=/usr
/share
/info \
54 --libexecdir
=/usr
/lib \
55 --localstatedir
=/var \
56 --mandir=/usr
/share
/man \
59 $(DISABLE_LARGEFILE
) \
65 --with-libxml-prefix
="$(STAGING_DIR)/usr" \
66 --with-libxml-include-prefix
="$(STAGING_DIR)/usr/include" \
67 --with-libxml-libs-prefix
="$(STAGING_DIR)/usr/lib" \
77 rm -rf
$(PKG_INSTALL_DIR
)
78 mkdir
-p
$(PKG_INSTALL_DIR
)
79 $(MAKE
) -C
$(PKG_BUILD_DIR
) \
80 DESTDIR
="$(PKG_INSTALL_DIR)" \
84 define Package
/libxslt
/install
85 install -m0755
-d
$(1)/usr
/lib
86 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libxslt.so.
* $(1)/usr
/lib
/
89 define Build
/InstallDev
90 mkdir
-p
$(STAGING_DIR
)/usr
/bin
91 $(CP
) $(PKG_INSTALL_DIR
)/usr
/bin
/xslt-config
$(STAGING_DIR
)/usr
/bin
/
92 mkdir
-p
$(STAGING_DIR
)/usr
/include
93 $(CP
) $(PKG_INSTALL_DIR
)/usr
/include/libxslt
$(STAGING_DIR
)/usr
/include/
94 mkdir
-p
$(STAGING_DIR
)/usr
/lib
95 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/libxslt.
{a
,so
*} $(STAGING_DIR
)/usr
/lib
/
96 mkdir
-p
$(STAGING_DIR
)/usr
/lib
/pkgconfig
97 $(CP
) $(PKG_INSTALL_DIR
)/usr
/lib
/pkgconfig
/libxslt.
pc $(STAGING_DIR
)/usr
/lib
/pkgconfig
/
98 $(SED
) 's,-I$$$${includedir},,g' $(STAGING_DIR
)/usr
/bin
/xslt-config
99 $(SED
) 's,-L$$$${libdir},,g' $(STAGING_DIR
)/usr
/bin
/xslt-config
100 $(SED
) 's,-I$(STAGING_DIR)/usr/include,,g' $(STAGING_DIR
)/usr
/bin
/xslt-config
101 $(SED
) 's,-L$(STAGING_DIR)/usr/lib,,g' $(STAGING_DIR
)/usr
/bin
/xslt-config
102 $(SED
) 's,-I$$$${includedir},,g' $(STAGING_DIR
)/usr
/lib
/pkgconfig
/libxslt.
pc
103 $(SED
) 's,-L$$$${libdir},,g' $(STAGING_DIR
)/usr
/lib
/pkgconfig
/libxslt.
pc
104 $(SED
) 's,-I$(STAGING_DIR)/usr/include,,g' $(STAGING_DIR
)/usr
/lib
/pkgconfig
/libxslt.
pc
105 $(SED
) 's,-L$(STAGING_DIR)/usr/lib,,g' $(STAGING_DIR
)/usr
/lib
/pkgconfig
/libxslt.
pc
108 define Build
/UninstallDev
110 $(STAGING_DIR
)/usr
/bin
/xslt-config \
111 $(STAGING_DIR
)/usr
/include/libxslt \
112 $(STAGING_DIR
)/usr
/lib
/libxslt.
{a
,so
*} \
113 $(STAGING_DIR
)/usr
/lib
/pkgconfig
/libxslt.
pc
116 $(eval
$(call BuildPackage
,libxslt
))