[riot-notifications] [RIOT-OS/RIOT] make/pkg: allow to set SOURCE_LOCAL per pkg (#11533)

Kaspar Schleiser notifications at github.com
Fri May 17 11:12:07 CEST 2019


kaspar030 requested changes on this pull request.



> @@ -3,6 +3,7 @@
 #
 PKG_DIR?=$(CURDIR)
 PKG_BUILDDIR?=$(PKGDIRBASE)/$(PKG_NAME)
+PKG_SOURCE_LOCAL ?= $(PKG_$(shell echo $(PKG_NAME) | tr a-z A-Z)_SOURCE_LOCAL)

I'd prefer ```PKG_SOURCE_LOCAL ?= $(PKG_SOURCE_LOCAL.$(PKG_NAME))``` to be more in line with the proposal in https://github.com/RIOT-OS/RIOT/pull/10928.
It also removes the extra subshell call just to uppercase the package name

That would also allow sth like ```foreach pkg in $USEPKG) do export $(PKG_SOURCE_LOCAL.$(PKG_NAME))```.

Unfortunately shell doesn't allow dots in variable names, so when overriding from the command line, this would have to be specified as make argument, e.g.:

```
# works:
make PKG_SOURCE_LOCAL.heatshrink=~/src/heatshrink

# doesn't work:
PKG_SOURCE_LOCAL.heatshrink=~/src/heatshrink make

# beware: doesn't work either:
PKG_SOURCE_LOCAL_CN-CBOR=foo make
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/RIOT-OS/RIOT/pull/11533#pullrequestreview-238814757
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.riot-os.org/pipermail/notifications/attachments/20190517/227f6693/attachment.html>


More information about the notifications mailing list