f8b838087059598c0d8b2ce635431302cef9e374
[packages.git] / libs / ptlib / Makefile
1
2 # Copyright (C) 2006-2009 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6
7 include $(TOPDIR)/rules.mk
8
9 PKG_NAME:=ptlib
10 PKG_VERSION:=2.10.9
11 PKG_RELEASE:=1
12
13 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
14 PKG_SOURCE_URL:=@SF/opalvoip
15 PKG_MD5SUM:=
16
17 include $(INCLUDE_DIR)/package.mk
18
19 define Package/ptlib
20   SECTION:=libs
21   CATEGORY:=Libraries
22   DEPENDS:=+libexpat
23   TITLE:=Portable Tools library
24   URL:=http://www.opalvoip.org/
25 endef
26
27 define Package/ptlib/description
28  PTLib is a moderately large class library that has its genesis many years ago as
29  PWLib (portable Windows Library), a method to product applications to run on both
30  Microsoft Windows and Unix X-Windows systems. It also was to have a Macintosh port
31  as well but that never eventuated. The parts of the library relating to GUI
32  functions have long been removed as other class libraries such as wxWidgets were
33  much more advanced.
34 endef
35
36 TARGET_CFLAGS += $(FPIC)
37
38 CONFIGURE_ARGS += \
39         --enable-minsize \
40         --enable-opal \
41         --enable-internalregex \
42         --enable-audio \
43         --disable-alsa \
44         --disable-asn \
45         --disable-avc \
46         --enable-configfile \
47         --disable-dc \
48         --disable-dtmf \
49         --enable-expat \
50         --disable-ftp \
51         --disable-http \
52         --disable-httpsvc \
53         --disable-jabber \
54         --disable-odbc \
55         --disable-openldap \
56         --disable-openssl \
57         --disable-oss \
58         --disable-pipechan \
59         --disable-plugins \
60         --disable-pop3smtp \
61         --disable-remconn \
62         --enable-resolver \
63         --enable-qos \
64         --disable-sasl \
65         --disable-sdl \
66         --disable-serial \
67         --disable-shm-video \
68         --disable-snmp \
69         --disable-soap \
70         --disable-socks \
71         --enable-stun \
72         --disable-telnet \
73         --disable-tts \
74         --disable-v4l \
75         --disable-v4l2 \
76         --disable-bsdvideo \
77         --disable-video \
78         --disable-vxml \
79         --enable-wavfile \
80         --disable-xmlrpc \
81
82 CONFIGURE_VARS += \
83         CXXFLAGS="$(TARGET_CFLAGS) -fno-builtin -fno-rtti" \
84
85 CONFIGURE_CMD = ./configure
86
87 define Build/Configure/Default
88         (cd $(PKG_BUILD_DIR)/$(CONFIGURE_PATH)/$(strip $(3)); \
89         if [ -x $(CONFIGURE_CMD) ]; then \
90                 $(CP) $(SCRIPT_DIR)/config.{guess,sub} $(PKG_BUILD_DIR)/$(3)/ && \
91                 $(CONFIGURE_VARS) \
92                 $(2) \
93                 $(CONFIGURE_CMD) \
94                 $(CONFIGURE_ARGS) \
95                 $(1); \
96         fi; \
97         )
98 endef
99
100 MAKE_FLAGS += optnoshared
101
102 define Build/InstallDev
103         ln -sf $(PKG_NAME)_$(PKG_VERSION) $(BUILD_DIR)/$(PKG_NAME)
104         $(SED) 's|//\(#include <ptlib/sound.h>\)|\1|' $(PKG_BUILD_DIR)/include/ptlib.h
105 endef
106
107 $(eval $(call BuildPackage,ptlib))