fix Makefile

error_handling
Avril 4 years ago
parent 460972a7aa
commit 4b52a36eaf
Signed by: flanchan
GPG Key ID: 284488987C31F630

@ -46,23 +46,25 @@ OBJ = $(OBJ_C) $(OBJ_CXX)
# Phonies # Phonies
.PHONY: release .PHONY: release
release: | dirs lib$(PROJECT)-release.a release: | dirs
-$(MAKE) clean-rebuild $(MAKE) lib$(PROJECT).a
-$(MAKE) dirs @$(MAKE) clean-rebuild >> /dev/null
$(MAKE) lib$(PROJECT)-release.so @$(MAKE) dirs >> /dev/null
$(MAKE) lib$(PROJECT).so
.PHONY: debug .PHONY: debug
debug: | dirs lib$(PROJECT)-debug.a debug: | dirs
-$(MAKE) clean-rebuild $(MAKE) lib$(PROJECT)-debug.a
-$(MAKE) dirs @$(MAKE) clean-rebuild >> /dev/null
@$(MAKE) dirs >> /dev/null
$(MAKE) lib$(PROJECT)-debug.so $(MAKE) lib$(PROJECT)-debug.so
# Rebuild both release and debug targets from scratch # Rebuild both release and debug targets from scratch
.PHONY: all .PHONY: all
all: | clean all: | clean
-$(MAKE) release @$(MAKE) release
-$(MAKE) clean-rebuild @$(MAKE) clean-rebuild
-$(MAKE) debug @$(MAKE) debug
.PHONY: install .PHONY: install
.PHONY: uninstall .PHONY: uninstall
@ -115,7 +117,7 @@ clean-rebuild:
clean: clean-rebuild clean: clean-rebuild
rm -f lib$(PROJECT){,-{release,debug,pgo}}.{a,so} rm -f lib$(PROJECT){,-{release,debug,pgo}}.{a,so}
install: | dirs lib$(PROJECT).a lib$(PROJECT).so install: | lib$(PROJECT).a lib$(PROJECT).so
install -d $(DESTDIR)$(PREFIX)/lib/ install -d $(DESTDIR)$(PREFIX)/lib/
install -m 644 lib$(PROJECT).a $(DESTDIR)$(PREFIX)/lib/ install -m 644 lib$(PROJECT).a $(DESTDIR)$(PREFIX)/lib/
install -m 755 lib$(PROJECT).so $(DESTDIR)$(PREFIX)/lib/ install -m 755 lib$(PROJECT).so $(DESTDIR)$(PREFIX)/lib/

Loading…
Cancel
Save