pcre: update to version 8.11
[openwrt/svn-archive/archive.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.11
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
15 PKG_SOURCE_URL:=@SF/pcre
16 PKG_MD5SUM:=ef907b8792ec7f90f0dcd773848f0b3b
17
18 PKG_FIXUP:=libtool
19
20 PKG_INSTALL:=1
21
22 include $(INCLUDE_DIR)/package.mk
23
24 define Package/libpcre
25 SECTION:=libs
26 CATEGORY:=Libraries
27 TITLE:=A Perl Compatible Regular Expression library
28 URL:=http://www.pcre.org/
29 endef
30
31 TARGET_CFLAGS += $(FPIC)
32
33 CONFIGURE_ARGS += \
34 --enable-utf8 \
35 --disable-cpp
36
37 MAKE_FLAGS += \
38 CFLAGS="$(TARGET_CFLAGS)"
39
40 define Build/InstallDev
41 $(INSTALL_DIR) $(1)/usr/bin
42 $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/bin/pcre-config $(1)/usr/bin/
43
44 $(INSTALL_DIR) $(2)/bin
45 $(LN) $(STAGING_DIR)/usr/bin/pcre-config $(2)/bin
46
47 $(INSTALL_DIR) $(1)/usr/include
48 $(CP) $(PKG_INSTALL_DIR)/usr/include/pcre{,posix}.h $(1)/usr/include/
49
50 $(INSTALL_DIR) $(1)/usr/lib
51 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre{,posix}.{a,so*} $(1)/usr/lib/
52
53 $(INSTALL_DIR) $(1)/usr/lib/pkgconfig
54 $(CP) $(PKG_INSTALL_DIR)/usr/lib/pkgconfig/libpcre.pc $(1)/usr/lib/pkgconfig/
55
56 endef
57
58 define Package/libpcre/install
59 $(INSTALL_DIR) $(1)/usr/lib
60 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libpcre{,posix}.so.* $(1)/usr/lib/
61 endef
62
63 $(eval $(call BuildPackage,libpcre))