93c175c9d706fb2d8b69dd8ef6e75591a8fd2166
[openwrt/svn-archive/archive.git] / libs / cgilib / 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
8 include $(TOPDIR)/rules.mk
9
10 PKG_NAME:=cgilib
11 PKG_VERSION:=0.7
12 PKG_RELEASE:=1
13
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_SOURCE_URL:=http://www.infodrom.org/projects/cgilib/download
16 PKG_MD5SUM:=2c7053f58dfb06f7a80a112797ed7e86
17
18 include $(INCLUDE_DIR)/package.mk
19
20 define Package/cgilib
21 SECTION:=libs
22 CATEGORY:=Libraries
23 TITLE:=Simple CGI Library
24 URL:=http://www.infodrom.org/projects/cgilib/
25 endef
26
27 TARGET_CFLAGS += $(FPIC)
28
29 define Build/Compile
30 $(MAKE) -C $(PKG_BUILD_DIR) \
31 $(TARGET_CONFIGURE_OPTS) \
32 OFLAGS="$(TARGET_CFLAGS)" \
33 DESTDIR="$(PKG_INSTALL_DIR)" \
34 install
35 endef
36
37 define Build/InstallDev
38 mkdir -p $(1)/usr/include
39 $(CP) $(PKG_INSTALL_DIR)/usr/include/cgi.h $(1)/usr/include/
40 mkdir -p $(1)/usr/lib
41 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcgi.{a,so*} $(1)/usr/lib/
42 endef
43
44 define Package/cgilib/install
45 $(INSTALL_DIR) $(1)/usr/lib
46 $(CP) $(PKG_INSTALL_DIR)/usr/lib/libcgi.so.* $(1)/usr/lib/
47 endef
48
49 $(eval $(call BuildPackage,cgilib))