2 # Copyright (C) 2008-2011 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
=2012-02-24
14 PKG_VERSION
:=$(UCI_VERSION
)$(if
$(UCI_RELEASE
),.
$(UCI_RELEASE
))
16 PKG_REV
:=d3722382bdd467d1c705911450120be75426406f
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
:=476039f871b69d756f3b04498130c27e
27 include $(INCLUDE_DIR
)/package.mk
28 include $(INCLUDE_DIR
)/cmake.mk
30 # set to 1 to enable debugging
36 TITLE
:=C library for the Unified Configuration Interface
(UCI
)
43 TITLE
:=Utility for the Unified Configuration Interface
(UCI
)
46 define Package
/libuci-lua
49 DEPENDS
:=+libuci
+liblua
50 TITLE
:=Lua plugin for UCI
53 TARGET_CFLAGS
+= -I
$(STAGING_DIR
)/usr
/include
54 TARGET_LDFLAGS
+= -L
$(STAGING_DIR
)/usr
/lib
57 -DLUAPATH
=/usr
/lib
/lua \
58 $(if
$(DEBUG
),-DUCI_DEBUG
=ON
)
60 define Package
/libuci
/install
61 $(INSTALL_DIR
) $(1)/lib
62 $(CP
) $(PKG_BUILD_DIR
)/libuci.so
* $(1)/lib
/
65 define Package
/libuci-lua
/install
66 $(INSTALL_DIR
) $(1)/usr
/lib
/lua
67 $(CP
) $(PKG_BUILD_DIR
)/lua
/uci.so
$(1)/usr
/lib
/lua
/
70 define Package
/uci
/install
71 $(INSTALL_DIR
) $(1)/etc
/uci-defaults
72 $(INSTALL_DIR
) $(1)/sbin
73 $(INSTALL_BIN
) $(PKG_BUILD_DIR
)/uci
$(1)/sbin
/
77 define Build
/InstallDev
78 $(INSTALL_DIR
) $(1)/usr
/include
79 $(CP
) $(PKG_BUILD_DIR
)/uci
{,_config
,map
}.h
$(1)/usr
/include
80 $(INSTALL_DIR
) $(1)/usr
/lib
81 $(CP
) $(PKG_BUILD_DIR
)/libuci.so
* $(1)/usr
/lib
82 $(CP
) $(PKG_BUILD_DIR
)/libuci.a
$(1)/usr
/lib
83 $(CP
) $(PKG_BUILD_DIR
)/libucimap.a
$(1)/usr
/lib
86 $(eval
$(call BuildPackage
,uci
))
87 $(eval
$(call BuildPackage
,libuci
))
88 $(eval
$(call BuildPackage
,libuci-lua
))