apps/Makefile: Make libapps overwritable.
This commit is contained in:
parent
1342426431
commit
4b49362719
@ -84,10 +84,10 @@ endif
|
|||||||
# Module install directory
|
# Module install directory
|
||||||
|
|
||||||
ifeq ($(WINTOOL),y)
|
ifeq ($(WINTOOL),y)
|
||||||
BIN = "${shell cygpath -w $(APPDIR)$(DELIM)libapps$(LIBEXT)}"
|
BIN ?= "${shell cygpath -w $(APPDIR)$(DELIM)libapps$(LIBEXT)}"
|
||||||
INSTALL_DIR = "${shell cygpath -w $(BINDIR)}"
|
INSTALL_DIR = "${shell cygpath -w $(BINDIR)}"
|
||||||
else
|
else
|
||||||
BIN = $(APPDIR)$(DELIM)libapps$(LIBEXT)
|
BIN ?= $(APPDIR)$(DELIM)libapps$(LIBEXT)
|
||||||
INSTALL_DIR = $(BINDIR)
|
INSTALL_DIR = $(BINDIR)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@ -99,7 +99,7 @@ VPATH += :.
|
|||||||
|
|
||||||
all:: .built
|
all:: .built
|
||||||
.PHONY: clean preconfig depend distclean
|
.PHONY: clean preconfig depend distclean
|
||||||
.PRECIOUS: $(APPDIR)/libapps$(LIBEXT)
|
.PRECIOUS: $(BIN)
|
||||||
|
|
||||||
ifneq ($(CONFIG_BUILD_LOADABLE),y)
|
ifneq ($(CONFIG_BUILD_LOADABLE),y)
|
||||||
|
|
||||||
|
@ -51,7 +51,7 @@ define REGISTER
|
|||||||
endef
|
endef
|
||||||
else
|
else
|
||||||
define REGISTER
|
define REGISTER
|
||||||
$(Q) echo "Register: $1 $4"
|
$(Q) echo "Register: $1"
|
||||||
$(Q) echo "{ \"$1\", $2, $3, $4 }," > "$(BUILTIN_REGISTRY)$(DELIM)$1.bdat"
|
$(Q) echo "{ \"$1\", $2, $3, $4 }," > "$(BUILTIN_REGISTRY)$(DELIM)$1.bdat"
|
||||||
$(Q) if [ ! -z $4 ]; then \
|
$(Q) if [ ! -z $4 ]; then \
|
||||||
echo "int $4(int argc, char *argv[]);" > "$(BUILTIN_REGISTRY)$(DELIM)$1.pdat"; \
|
echo "int $4(int argc, char *argv[]);" > "$(BUILTIN_REGISTRY)$(DELIM)$1.pdat"; \
|
||||||
@ -113,5 +113,5 @@ CFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" "$(APPDIR)$(DELIM)include"}
|
|||||||
CXXFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" "$(APPDIR)$(DELIM)include"}
|
CXXFLAGS += ${shell $(INCDIR) $(INCDIROPT) "$(CC)" "$(APPDIR)$(DELIM)include"}
|
||||||
|
|
||||||
ifneq ($(CONFIG_BUILD_KERNEL),y)
|
ifneq ($(CONFIG_BUILD_KERNEL),y)
|
||||||
LDLIBS = $(APPDIR)/libapps.a
|
LDLIBS ?= $(APPDIR)/libapps.a
|
||||||
endif
|
endif
|
||||||
|
4
Makefile
4
Makefile
@ -70,7 +70,7 @@ BINDIR = $(APPDIR)$(DELIM)bin
|
|||||||
|
|
||||||
# The final build target
|
# The final build target
|
||||||
|
|
||||||
BIN = libapps$(LIBEXT)
|
BIN ?= libapps$(LIBEXT)
|
||||||
|
|
||||||
# Symbol table for loadable apps.
|
# Symbol table for loadable apps.
|
||||||
|
|
||||||
@ -81,7 +81,7 @@ SYMTABOBJ = $(SYMTABSRC:.c=$(OBJEXT))
|
|||||||
|
|
||||||
all: $(BIN)
|
all: $(BIN)
|
||||||
.PHONY: import install dirlinks context context_serialize clean_context context_rest export .depdirs preconfig depend clean distclean
|
.PHONY: import install dirlinks context context_serialize clean_context context_rest export .depdirs preconfig depend clean distclean
|
||||||
.PRECIOUS: libapps$(LIBEXT)
|
.PRECIOUS: $(BIN)
|
||||||
|
|
||||||
define MAKE_template
|
define MAKE_template
|
||||||
$(Q) cd $(1) && $(MAKE) $(2) TOPDIR="$(TOPDIR)" APPDIR="$(APPDIR)" BINDIR="$(BINDIR)"
|
$(Q) cd $(1) && $(MAKE) $(2) TOPDIR="$(TOPDIR)" APPDIR="$(APPDIR)" BINDIR="$(BINDIR)"
|
||||||
|
Loading…
Reference in New Issue
Block a user