Commit c0b54070 authored by Philippe Gerum's avatar Philippe Gerum
Browse files

build: copy tidbits only if install_all is given



Do build them unconditionally though.
Signed-off-by: default avatarPhilippe Gerum <rpm@xenomai.org>
parent 654717f0
...@@ -23,7 +23,7 @@ $(O_DIR)/latmus: override CFLAGS := -I zephyr/latmon/src $(CFLAGS) ...@@ -23,7 +23,7 @@ $(O_DIR)/latmus: override CFLAGS := -I zephyr/latmon/src $(CFLAGS)
all: output-Makefile $(DEPFILES) $(TARGETS) all: output-Makefile $(DEPFILES) $(TARGETS)
install: all install install_all: all
$(call inst-cmd,benchmarks,$(Q)for bin in $(BINARIES); do \ $(call inst-cmd,benchmarks,$(Q)for bin in $(BINARIES); do \
$(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(bindir); \ $(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(bindir); \
done) done)
......
...@@ -93,7 +93,7 @@ ld-cmd = $(call run-cmd,LD,$(notdir $(1)),$(2)) ...@@ -93,7 +93,7 @@ ld-cmd = $(call run-cmd,LD,$(notdir $(1)),$(2))
ar-cmd = $(call run-cmd,AR,$(notdir $(1)),$(2) $(if $(Q),2>/dev/null)) ar-cmd = $(call run-cmd,AR,$(notdir $(1)),$(2) $(if $(Q),2>/dev/null))
inst-cmd = $(call run-cmd,INST,$(notdir $(1)),$(2)) inst-cmd = $(call run-cmd,INST,$(notdir $(1)),$(2))
MAIN_GOALS := all clean clobber mrproper install MAIN_GOALS := all clean clobber mrproper install install_all
_all: _all:
......
...@@ -28,7 +28,7 @@ override LDFLAGS := $(LDFLAGS) -lpthread -lrt ...@@ -28,7 +28,7 @@ override LDFLAGS := $(LDFLAGS) -lpthread -lrt
all: output-Makefile $(DEPFILES) $(TARGETS) all: output-Makefile $(DEPFILES) $(TARGETS)
install: all install install_all: all
$(call inst-cmd,$(SOLIBNAME),$(INSTALL) -D $(O_DIR)/$(SOLIBNAME) -t $(DESTDIR)/$(libdir)) $(call inst-cmd,$(SOLIBNAME),$(INSTALL) -D $(O_DIR)/$(SOLIBNAME) -t $(DESTDIR)/$(libdir))
@$(LN_S) $(SOLIBNAME) $(DESTDIR)/$(libdir)/$(DTSONAME) @$(LN_S) $(SOLIBNAME) $(DESTDIR)/$(libdir)/$(DTSONAME)
@$(LN_S) $(DTSONAME) $(DESTDIR)/$(libdir)/$(SONAME) @$(LN_S) $(DTSONAME) $(DESTDIR)/$(libdir)/$(SONAME)
......
...@@ -32,7 +32,7 @@ clean clobber mrproper: output-Makefile ...@@ -32,7 +32,7 @@ clean clobber mrproper: output-Makefile
$(Q)$(RM) -f $(O_DIR)/.uapi_stamp $(O_UAPI)/asm $(O_UAPI)/evl $(Q)$(RM) -f $(O_DIR)/.uapi_stamp $(O_UAPI)/asm $(O_UAPI)/evl
$(Q)test -d $(O_UAPI) && $(RMDIR_SAFE) $(O_UAPI) || : $(Q)test -d $(O_UAPI) && $(RMDIR_SAFE) $(O_UAPI) || :
install: all install install_all: all
$(Q)$(MKDIR_P) $(DESTDIR)/$(includedir)/uapi $(Q)$(MKDIR_P) $(DESTDIR)/$(includedir)/uapi
$(call inst-cmd,uapi-headers,cd $(O_UAPI) && find -L evl \! \( -name '*~' \) -type f | $(CPIO) -Lpdum --quiet $(DESTDIR)/$(includedir)/uapi) $(call inst-cmd,uapi-headers,cd $(O_UAPI) && find -L evl \! \( -name '*~' \) -type f | $(CPIO) -Lpdum --quiet $(DESTDIR)/$(includedir)/uapi)
$(call inst-cmd,interface-headers,find evl \! \( -name '*~' \) -type f | $(CPIO) -Lpdum --quiet $(DESTDIR)/$(includedir)) $(call inst-cmd,interface-headers,find evl \! \( -name '*~' \) -type f | $(CPIO) -Lpdum --quiet $(DESTDIR)/$(includedir))
......
...@@ -29,7 +29,7 @@ override LDFLAGS := $(LDFLAGS) -lpthread -lrt ...@@ -29,7 +29,7 @@ override LDFLAGS := $(LDFLAGS) -lpthread -lrt
all: output-Makefile $(DEPFILES) $(TARGETS) all: output-Makefile $(DEPFILES) $(TARGETS)
install: all install install_all: all
$(call inst-cmd,$(SOLIBNAME),$(INSTALL) -D $(O_DIR)/$(SOLIBNAME) -t $(DESTDIR)/$(libdir)) $(call inst-cmd,$(SOLIBNAME),$(INSTALL) -D $(O_DIR)/$(SOLIBNAME) -t $(DESTDIR)/$(libdir))
@$(LN_S) $(SOLIBNAME) $(DESTDIR)/$(libdir)/$(DTSONAME) @$(LN_S) $(SOLIBNAME) $(DESTDIR)/$(libdir)/$(DTSONAME)
@$(LN_S) $(DTSONAME) $(DESTDIR)/$(libdir)/$(SONAME) @$(LN_S) $(DTSONAME) $(DESTDIR)/$(libdir)/$(SONAME)
......
...@@ -38,7 +38,7 @@ all: output-Makefile $(DEPFILES) $(TARGETS) ...@@ -38,7 +38,7 @@ all: output-Makefile $(DEPFILES) $(TARGETS)
$(TARGETS): $(HELPOBJ) $(HELPOBJ_ESHI) $(TARGETS): $(HELPOBJ) $(HELPOBJ_ESHI)
install: all install install_all: all
$(call inst-cmd,tests,$(Q)for bin in $(TESTSRC:%.c=%); do \ $(call inst-cmd,tests,$(Q)for bin in $(TESTSRC:%.c=%); do \
$(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(testdir); \ $(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(testdir); \
done) done)
......
...@@ -19,9 +19,12 @@ $(TARGETS): ...@@ -19,9 +19,12 @@ $(TARGETS):
all: output-Makefile $(DEPFILES) $(TARGETS) all: output-Makefile $(DEPFILES) $(TARGETS)
# Install only if install_all is given
install: all install: all
$(call inst-cmd,tidbits, \
for bin in $(TIDBITS); do \ install_all: all
$(call inst-cmd,tidbits, \
for bin in $(TIDBITS); do \
$(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(tbitsdir); done) $(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(tbitsdir); done)
clean clobber mrproper: output-Makefile clean clobber mrproper: output-Makefile
......
...@@ -27,7 +27,7 @@ $(TARGETS): ...@@ -27,7 +27,7 @@ $(TARGETS):
all: output-Makefile $(DEPFILES) $(TARGETS) all: output-Makefile $(DEPFILES) $(TARGETS)
install: all install install_all: all
$(call inst-cmd,utilities, \ $(call inst-cmd,utilities, \
for bin in $(COMMANDS); do \ for bin in $(COMMANDS); do \
$(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(bindir); done) $(INSTALL) -D $(O_DIR)/$$bin -t $(DESTDIR)/$(bindir); done)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment