2 # Copyright (C) 2008-2013 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
8 include $(TOPDIR
)/rules.mk
10 UCI_VERSION
=2013-05-26
14 PKG_VERSION
:=$(UCI_VERSION
)$(if
$(UCI_RELEASE
),.
$(UCI_RELEASE
))
16 PKG_REV
:=9ef6964362f917ba035020d439d05b36abfe5bb9
18 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
19 PKG_SOURCE_URL
:=git
://nbd.name
/uci.git
20 PKG_SOURCE_SUBDIR
:=uci-
$(PKG_VERSION
)
21 PKG_SOURCE_VERSION
:=$(PKG_REV
)
23 PKG_MIRROR_MD5SUM
:=05585c577ae39173920d0a44bda9537a
25 PKG_LICENSE
:=LGPLv2.1 GPLv2
28 PKG_MAINTAINER
:=Felix Fietkau
<nbd@openwrt.org
>
32 include $(INCLUDE_DIR
)/package.mk
33 include $(INCLUDE_DIR
)/cmake.mk
35 # set to 1 to enable debugging
41 TITLE
:=C library for the Unified Configuration Interface
(UCI
)
48 TITLE
:=Utility for the Unified Configuration Interface
(UCI
)
51 define Package
/libuci-lua
54 DEPENDS
:=+libuci
+liblua
55 TITLE
:=Lua plugin for UCI
58 TARGET_CFLAGS
+= -I
$(STAGING_DIR
)/usr
/include
59 TARGET_LDFLAGS
+= -L
$(STAGING_DIR
)/usr
/lib
62 -DLUAPATH
=/usr
/lib
/lua \
63 $(if
$(DEBUG
),-DUCI_DEBUG
=ON
)
65 define Package
/libuci
/install
66 $(INSTALL_DIR
) $(1)/lib
67 $(CP
) $(PKG_BUILD_DIR
)/libuci.so
* $(1)/lib
/
70 define Package
/libuci-lua
/install
71 $(INSTALL_DIR
) $(1)/usr
/lib
/lua
72 $(CP
) $(PKG_BUILD_DIR
)/lua
/uci.so
$(1)/usr
/lib
/lua
/
75 define Package
/uci
/install
76 $(INSTALL_DIR
) $(1)/etc
/uci-defaults
77 $(INSTALL_DIR
) $(1)/sbin
78 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/uci
$(1)/sbin
/
82 define Build
/InstallDev
83 $(INSTALL_DIR
) $(1)/usr
/include
84 $(CP
) $(PKG_BUILD_DIR
)/uci
{,_config
,map
}.h
$(1)/usr
/include
85 $(INSTALL_DIR
) $(1)/usr
/lib
86 $(CP
) $(PKG_BUILD_DIR
)/libuci.so
* $(1)/usr
/lib
87 $(CP
) $(PKG_BUILD_DIR
)/libucimap.a
$(1)/usr
/lib
90 $(eval
$(call BuildPackage
,uci
))
91 $(eval
$(call BuildPackage
,libuci
))
92 $(eval
$(call BuildPackage
,libuci-lua
))