62b60aa9f04912dc1b1f5b3d30aef0f1e82c9290
[packages.git] / libs / wxbase / Makefile
1
2 # Copyright (C) 2007-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 # $Id$
8
9 include $(TOPDIR)/rules.mk
10
11 PKG_NAME:=wxbase
12 PKG_VERSION:=2.8.7
13 PKG_RELEASE:=2
14
15 PKG_SOURCE:=wxGTK-$(PKG_VERSION).tar.bz2
16 PKG_SOURCE_URL:=@SF/wxwindows
17 PKG_MD5SUM:=b25e85eeee524903214ebb520753f4bd
18
19 PKG_BUILD_DIR:=$(BUILD_DIR)/wxGTK-$(PKG_VERSION)
20
21 include $(INCLUDE_DIR)/package.mk
22
23 define Package/libwxbase
24   SECTION:=libs
25   CATEGORY:=Libraries
26   TITLE:=Cross-platform C++ framework
27   URL:=http://www.wxwidgets.org/
28   DEPENDS:=+libexpat +libstdcpp +zlib
29 endef
30
31 define Package/libwxbase/description
32  wxBase contains most of the non-GUI classes from the wxWindows cross-
33  -platform C++ framework. There are 2 categories: generally useful portable 
34  code (date/time handling, command line parsing, regular expression support) 
35  and wrappers for the OS objects (files, directories, sockets, threads, 
36  etc.) allowing you to write portable programs easily.
37 endef
38
39 TARGET_CFLAGS += $(FPIC)
40
41 # XXX: aMule *needs* the following configure options to be enabled:
42 #       --enable-intl
43 #       --enable-largefile
44 #       --disable-no_rtti
45 #       --with-regex
46 CONFIGURE_ARGS+= \
47         --enable-shared \
48         --disable-rpath \
49         --with-gnu-ld \
50         --disable-gui \
51         --disable-monolithic \
52         --enable-plugins \
53         --disable-universal \
54         --disable-nanox \
55         --disable-gtk2 \
56         --disable-gpe \
57         --disable-optimise \
58         --disable-debug \
59         --disable-stl \
60         --disable-omf \
61         --disable-debug_flag \
62         --disable-debug_info \
63         --disable-debug_gdb \
64         --disable-debug_cntxt \
65         --disable-mem_tracing \
66         --disable-profile \
67         --disable-no_rtti \
68         --disable-no_exceptions \
69         --disable-compat22 \
70         --disable-compat24 \
71         --enable-intl \
72         --disable-backtrace \
73         --enable-exceptions \
74         --disable-unicode \
75         --disable-sound \
76         --enable-largefile \
77         \
78         --without-gtk \
79         --without-motif \
80         --without-mac \
81         --without-cocoa \
82         --without-wine \
83         --without-msw \
84         --without-pm \
85         --without-mgl \
86         --without-microwin \
87         --without-x11 \
88         --without-libpng \
89         --without-libjpeg \
90         --without-libtiff \
91         --without-libxpm \
92         --without-libmspack \
93         --without-sdl \
94         --without-gnomeprint \
95         --without-opengl \
96         --without-dmalloc \
97         --with-regex="sys" \
98         --with-zlib="sys" \
99         --without-odbc \
100         --with-expat="sys" \
101         --without-gtk-prefix \
102         --without-x \
103         --without-libiconv-prefix \
104         --without-sdl-prefix \
105         --without-cppunit-prefix \
106
107 define Build/Compile
108         $(MAKE) -C $(PKG_BUILD_DIR) \
109                 DESTDIR="$(PKG_INSTALL_DIR)" \
110                 all install
111 endef
112
113 define Build/InstallDev
114         $(INSTALL_DIR) $(1)/usr/bin $(1)/usr/include $(1)/usr/lib
115         $(CP) -L $(PKG_BUILD_DIR)/wx-config $(1)/usr/bin/
116         $(CP) $(PKG_INSTALL_DIR)/usr/include/wx-2.8 $(1)/usr/include/
117         $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwx_base{,_net,_xml}-2.8-*.so $(1)/usr/lib/
118         $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwx_base{,_net,_xml}-2.8.so.* $(1)/usr/lib/
119         $(CP) $(PKG_INSTALL_DIR)/usr/lib/wx $(1)/usr/lib/
120         $(SED) 's,-I$$$${includedir}/wx-2.8,-I$(STAGING_DIR)/usr/include/wx-2.8,g' $(1)/usr/bin/wx-config
121         $(SED) 's,-I$$$${libdir}/wx/include,-I$(STAGING_DIR)/usr/lib/wx/include,g' $(1)/usr/bin/wx-config
122 endef
123
124 define Package/libwxbase/install
125         $(INSTALL_DIR) $(1)/usr/lib
126         $(CP) $(PKG_INSTALL_DIR)/usr/lib/libwx_base{,_net,_xml}-2.8.so.* $(1)/usr/lib/
127 endef
128
129 $(eval $(call BuildPackage,libwxbase))