fe95bc9924ec3edca0e3b374e9c059435e1e563b
[openwrt.git] / package / libs / libbsd / Makefile
1 include $(TOPDIR)/rules.mk
2
3 PKG_NAME:=libbsd
4 PKG_VERSION:=0.3.0
5 PKG_RELEASE:=1
6
7 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
8 PKG_SOURCE_URL:=http://libbsd.freedesktop.org/releases
9 #PKG_MD5SUM:=d0870f2de55d59c1c8419f36e8fac150
10
11 PKG_LICENSE:=BSD-4c
12 PKG_LICENSE_FILES:=COPYING
13
14 include $(INCLUDE_DIR)/package.mk
15
16 PKG_INSTALL:=1
17
18 define Package/libbsd
19   SECTION:=libs
20   CATEGORY:=Libraries
21   DEPENDS:=@!USE_UCLIBC
22   TITLE:=common BSD library
23 endef
24
25 define Package/libbsd/description
26  This library provides useful functions commonly found on BSD systems, and lacking on others like GNU systems, thus making it easier to port projects with strong BSD origins, without needing to embed the same code over and over again on each project.
27 endef
28
29 define Build/InstallDev
30         $(INSTALL_DIR) \
31                 $(1)/lib \
32                 $(1)/usr/include
33
34         $(CP) \
35                 $(PKG_INSTALL_DIR)/lib/libbsd.so* \
36                 $(1)/lib/
37
38         $(CP) \
39                 $(PKG_INSTALL_DIR)/usr/include/* \
40                 $(1)/usr/include/
41
42         ( cd $(1)/lib ; ln -s libbsd.so.$(PKG_VERSION) libbsd.so )
43 endef
44
45 define Package/libbsd/install
46         $(INSTALL_DIR) \
47                 $(1)/lib
48
49         $(CP) \
50                 $(PKG_INSTALL_DIR)/lib/libbsd.so* \
51                 $(1)/lib/
52
53         ( cd $(1)/lib ; ln -s libbsd.so.$(PKG_VERSION) libbsd.so )
54 endef
55
56 $(eval $(call BuildPackage,libbsd))
57