Retain symlinks. $(INSTALL_*) copys the contens of a file, so if we want to keep
[openwrt/svn-archive/archive.git] / Xorg / lib / imlib2 / Makefile
1 #
2 # Copyright (C) 2006-2008 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # blogic@openwrt.org
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=imlib2
12 PKG_VERSION:=1.4.1
13 PKG_RELEASE:=3
14
15 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16 PKG_SOURCE_URL:=@SF/enlightenment
17 PKG_FIXUP:=libtool
18
19 include $(INCLUDE_DIR)/package.mk
20
21 PKG_INSTALL=1
22
23 define Package/imlib2
24 SECTION:=xorg-libraries
25 CATEGORY:=Xorg
26 SUBMENU:=libraries
27 TITLE:=Image library
28 DEPENDS:=+libX11 +giflib +libtiff +libjpeg +gtk1 +libnotimpl +libfreetype +libXext
29 endef
30
31 CONFIGURE_ARGS+=--disable-gtktest LIBS="-Wl,-rpath-link=$(STAGING_DIR)/usr/lib"
32 EXTRA_LDFLAGS+=-lnotimpl
33
34 define Build/InstallDev
35 $(INSTALL_DIR) $(1)/usr/{include,lib/pkgconfig}
36 $(INSTALL_DATA) \
37 $(PKG_INSTALL_DIR)/usr/include/* \
38 $(1)/usr/include/
39
40 $(CP) \
41 $(PKG_INSTALL_DIR)/usr/lib/*.{la,so*,a} \
42 $(1)/usr/lib/
43
44 $(INSTALL_DATA) \
45 $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/* \
46 $(1)/usr/lib/pkgconfig/
47
48 $(INSTALL_DIR) $(2)/bin
49 $(INSTALL_BIN) \
50 $(PKG_INSTALL_DIR)/usr/bin/imlib2-config \
51 $(2)/bin/
52 $(SED) \
53 's,^\(prefix\|exec_prefix\)=.*,\1=$(STAGING_DIR)/usr,g' \
54 $(2)/bin/imlib2-config
55 endef
56
57 define Package/imlib2/install
58 $(INSTALL_DIR) $(1)/usr/lib/imlib2/{loaders,filters}
59 $(CP) \
60 $(PKG_INSTALL_DIR)/usr/lib/*.so* \
61 $(1)/usr/lib/
62
63 $(INSTALL_DATA) \
64 $(PKG_INSTALL_DIR)/usr/lib/imlib2/filters/*.so* \
65 $(1)/usr/lib/imlib2/filters
66
67 $(INSTALL_DATA) \
68 $(PKG_INSTALL_DIR)/usr/lib/imlib2/loaders/*.so* \
69 $(1)/usr/lib/imlib2/loaders
70 endef
71
72 $(eval $(call BuildPackage,imlib2))