kopia lustrzana https://github.com/micropython/micropython
unix/Makefile: Allow to install all variants of the executable.
The install target is current broken when PROG is used to override the default executable name. This fixes it by removing the redundant TARGET variable and uses PROG directly instead. The install and uninstall targets are also moved to the common unix Makefile so that all variants can be installed in the same way.pull/5644/head
rodzic
c5f4268c99
commit
4af79e7694
|
@ -248,3 +248,12 @@ axtls: $(TOP)/lib/axtls/README
|
|||
$(TOP)/lib/axtls/README:
|
||||
@echo "You cloned without --recursive, fetching submodules for you."
|
||||
(cd $(TOP); git submodule update --init --recursive)
|
||||
|
||||
PREFIX = /usr/local
|
||||
BINDIR = $(DESTDIR)$(PREFIX)/bin
|
||||
|
||||
install: $(PROG)
|
||||
install -D $(PROG) $(BINDIR)/$(PROG)
|
||||
|
||||
uninstall:
|
||||
-rm $(BINDIR)/$(PROG)
|
||||
|
|
|
@ -1,16 +1,3 @@
|
|||
# This is the default variant when you `make` the Unix port.
|
||||
|
||||
PROG ?= micropython
|
||||
|
||||
# install micropython in /usr/local/bin
|
||||
TARGET = micropython
|
||||
PREFIX = /usr/local
|
||||
BINDIR = $(DESTDIR)$(PREFIX)/bin
|
||||
|
||||
install: micropython
|
||||
install -d $(BINDIR)
|
||||
install $(TARGET) $(BINDIR)/$(TARGET)
|
||||
|
||||
# uninstall micropython
|
||||
uninstall:
|
||||
-rm $(BINDIR)/$(TARGET)
|
||||
|
|
Ładowanie…
Reference in New Issue