12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788 |
- ifeq ($(filter bootstrap,$(MAKECMDGOALS)),)
- ifeq ($(wildcard Makefile),)
-
-
- $(warning There seems to be no Makefile in this directory.)
- $(warning You must run ./configure before running 'make'.)
- $(error Fatal Error)
- endif
- include ./Makefile
- include $(srcdir)/maintainer/maint.mk
- include $(srcdir)/maintainer/syntax-checks.mk
- else
- other-targets := $(filter-out bootstrap,$(MAKECMDGOALS))
- config-status := $(wildcard ./config.status)
- BOOTSTRAP_SHELL ?= /bin/sh
- export BOOTSTRAP_SHELL
- ifdef config-status
-
-
- srcdir := $(shell echo @srcdir@ | $(config-status) --file=-)
- ifndef srcdir
- $(error Could not obtain $$(srcdir) from $(config-status))
- endif
-
-
- old-configure-flags := $(shell $(config-status) --config)
- else
- srcdir := .
- old-configure-flags :=
- endif
- configure-flags := $(old-configure-flags) $(BOOTSTRAP_CONFIGURE_FLAGS)
- .PHONY: bootstrap
- bootstrap:
- cd $(srcdir) && $(SHELL) ./bootstrap
- $(srcdir)/configure $(configure-flags)
- $(MAKE) clean
- $(MAKE) check TESTS=t/get-sysconf
- ifdef other-targets
- $(other-targets): restart
- .PHONY: $(other-targets) restart
- restart: bootstrap; $(MAKE) $(AM_MAKEFLAGS) $(other-targets)
- endif
- endif
|