diff options
author | Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> | 2008-11-16 22:19:57 +0000 |
---|---|---|
committer | Yann E. MORIN" <yann.morin.1998@anciens.enib.fr> | 2008-11-16 22:19:57 +0000 |
commit | f15b8ade722394aa142ec4f63918c5b23b407193 (patch) | |
tree | 368315f6ac040dc2a33f8c85123ef680653c5b74 /Makefile.in | |
parent | 81f9d4d73eb40587d8c145d7d4e81396279b7247 (diff) | |
download | crosstool-ng-f15b8ade722394aa142ec4f63918c5b23b407193.tar.gz crosstool-ng-f15b8ade722394aa142ec4f63918c5b23b407193.tar.bz2 crosstool-ng-f15b8ade722394aa142ec4f63918c5b23b407193.zip |
Get rid of the local-test in Makefile.
/trunk/Makefile.in | 30 19 11 0 +++++++++++++++++++-----------
/trunk/docs/overview.txt | 25 13 12 0 +++++++++++++------------
2 files changed, 32 insertions(+), 23 deletions(-)
Diffstat (limited to 'Makefile.in')
-rw-r--r-- | Makefile.in | 30 |
1 files changed, 19 insertions, 11 deletions
diff --git a/Makefile.in b/Makefile.in index 1b19b2a2..598b02cb 100644 --- a/Makefile.in +++ b/Makefile.in @@ -39,7 +39,7 @@ TARGETS := bin lib doc man build: $(patsubst %,build-%,$(TARGETS)) -install: local-test build $(patsubst %,install-%,$(TARGETS)) +install: real-install clean: $(patsubst %,clean-%,$(TARGETS)) @@ -47,7 +47,7 @@ distclean: clean @echo " RM 'Makefile'" @rm -f Makefile -uninstall: local-test $(patsubst %,uninstall-%,$(TARGETS)) +uninstall: real-uninstall ############################################################################### # Specific make rules @@ -56,8 +56,6 @@ uninstall: local-test $(patsubst %,uninstall-%,$(TARGETS)) # Build rules build-bin: ct-ng - @echo " CHMOD '$<'" - @chmod a+x $< build-lib: @@ -100,16 +98,22 @@ clean-man: #-------------------------------------- # Check for --local setup -# If using locally, don't install -local-test: - @if [ "$(LOCAL)" = "1" ]; then \ - echo "You're using local copy as runtime. You can't (un)install."; \ - false; \ - fi +ifeq ($(strip $(LOCAL)),1) + +real-install: build + @echo " CHMOD 'ct-ng'" + @chmod a+x ct-ng + +real-uninstall: + @true + +else #-------------------------------------- # Install rules +real-install: build $(patsubst %,install-%,$(TARGETS)) + install-bin: $(DESTDIR)$(BINDIR) @echo " INST 'ct-ng'" @install -m 755 ct-ng "$(DESTDIR)$(BINDIR)/ct-ng" @@ -120,7 +124,7 @@ install-bin: $(DESTDIR)$(BINDIR) # is the goal of the install-lib rule to install the lib/ directory... install-lib: uninstall-lib $(DESTDIR)$(LIBDIR) install-lib-main install-lib-samples -install-lib-main: $(LIBDIR) +install-lib-main: $(DESTDIR)$(LIBDIR) @for src_dir in config kconfig patches scripts tools; do \ echo " INST '$${src_dir}/'"; \ tar cf - --exclude=.svn $${src_dir} |(cd "$(DESTDIR)$(LIBDIR)"; tar xf -); \ @@ -157,6 +161,8 @@ $(sort $(DESTDIR)$(BINDIR) $(DESTDIR)$(LIBDIR) $(DESTDIR)$(DOCDIR) $(DESTDIR)$(M #-------------------------------------- # Uninstall rules +real-uninstall: $(patsubst %,uninstall-%,$(TARGETS)) + uninstall-bin: @echo " RM '$(DESTDIR)$(BINDIR)/ct-ng'" @rm -f "$(DESTDIR)$(BINDIR)/ct-ng" @@ -172,3 +178,5 @@ uninstall-doc: uninstall-man: @echo " RM '$(DESTDIR)$(MANDIR)/ct-ng.1.gz'" @rm -f "$(DESTDIR)$(MANDIR)/ct-ng.1"{,.gz} + +endif # Not --local |