LuCI: split luci.mk into a common and a feed-internal file

Sven Roederer devel-sven at geroedel.de
Fri Jan 1 21:31:28 EST 2021


Hi,

based on Pauls recent idea "rules: add findrev function from LuCI" of reusing 
some LuCI-code, I'd like to point to a github-PR with a related suggestion:

https://github.com/openwrt/luci/pull/2637

As noted in the PR-message, it splits the current luci.mk file into two files. 
One for common code that might be usefull for other repos and the 2nd file 
containing the very LuCI-repo specific code.

Common code "luci-common.mk" can be included by other repos to use common 
constants (LUCI_MENU.*, LUCI_LANG.*, LUCI_LIBRARYDIR) and macros (findrev, 
PKG_GITBRANCH, SrcDiet, JsMin, Package/$(PKG_NAME)/install). But the code only 
relevant to the packages of the LuCI-repo (template-package-receips, $
(PKG_NAME),luci-base, LuciTranslation) stays in "luci.mk". 

For LuCI is reduces the size of the current makefile and makes it more easy to 
understand by new users. For "foreign" repos just including "luci-common.mk" 
reduces conflicts and clashes.

This code is used in the development-branch of the Freifunk Berlin Firmware 
since mid of 2019 without problems. Also Florian sees some benefits in this 
change, but it's still waiting for a final ACK or NACK by Jo-Philipp.

So probably this is now the best chance to get it also included into 20.xx .

Best Sven





More information about the openwrt-devel mailing list