# This is the default variant when you `make` the Unix port.

PROG ?= micropython

# install micropython in /usr/local/bin
TARGET = micropython
PREFIX = $(DESTDIR)/usr/local
BINDIR = $(PREFIX)/bin

install: micropython
	install -d $(BINDIR)
	install $(TARGET) $(BINDIR)/$(TARGET)

# uninstall micropython
uninstall:
	-rm $(BINDIR)/$(TARGET)

# 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)

Fix role of PREFIX when used to install.
unix/variants/standard: Fix role of PREFIX when used to install.

Currently it is not possible to override PREFIX when installing micropython
using the makefile.  It is common practice to be able to run something like
this:

    $ make install PREFIX=/usr DESTDIR=/tmp/staging

This fixes such usage.
