Add missing libtool fixups
[openwrt/svn-archive/packages.git] / libs / pcre / Makefile
1 #
2 # Copyright (C) 2006-2010 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:=pcre
11 PKG_VERSION:=8.01
12 PKG_RELEASE:=2
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:=@SF/pcre
16 PKG_MD5SUM:=413be1c23dabe91f637fb3770f640006
17
18 PKG_FIXUP:=libtool
19
20 include $(INCLUDE_DIR)/package.mk
21
22 define Package/libpcre
23 SECTION:=libs
24 CATEGORY:=Libraries
25 TITLE:=A Perl Compatible Regular Expression library
26 URL:=http://www.pcre.org/
27 endef
28
29 TARGET_CFLAGS += $(FPIC)
30
31 CONFIGURE_ARGS += \
32 --enable-shared \
33 --enable-static \
34 --enable-utf8 \
35 --disable-cpp \
36
37 MAKE_FLAGS += \
38 $(TARGET_CONFIGURE_OPTS) \
39 CFLAGS="$(TARGET_CFLAGS)" \
40 all \
41
42 define Build/InstallDev
43 $(INSTALL_DIR) $(1)/usr/bin $(2)/bin $(1)/usr/include $(1)/usr/lib
44 $(CP) $(PKG_BUILD_DIR)/pcre-config $(1)/usr/bin/
45 ln -sf $(STAGING_DIR)/usr/bin/pcre-config $(2)/bin
46 $(CP) $(PKG_BUILD_DIR)/pcre{,posix}.h $(1)/usr/include/
47 $(CP) $(PKG_BUILD_DIR)/.libs/libpcre{,posix}.{a,so*} $(1)/usr/lib/
48 endef
49
50 define Package/libpcre/install
51 $(INSTALL_DIR) $(1)/usr/lib
52 $(CP) $(PKG_BUILD_DIR)/.libs/libpcre{,posix}.so.* $(1)/usr/lib/
53 endef
54
55 $(eval $(call BuildPackage,libpcre))