You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
gentoo-overlay/app-crypt/tpm-emulator/files/tpm-emulator-0.5.1-parallel...

66 lines
1.9 KiB

commit b3d254296c1d3dbc6058f294041481af8972a661
Author: Andreas Niederl <rico32@gmx.net>
Date: Sun Aug 30 16:52:57 2009 +0200
fix version target in Makefile
diff --git a/Makefile b/Makefile
index 9260014..de54e52 100644
--- a/Makefile
+++ b/Makefile
@@ -12,33 +12,35 @@ VERSION_SUFFIX := .1
SUBDIRS := tpmd tpmd_dev tddl
-all: version all-recursive
+all: all-recursive
-version:
- @echo "#ifndef _TPM_VERSION_H_" > tpm/tpm_version.h
- @echo "#define _TPM_VERSION_H_" >> tpm/tpm_version.h
- @echo "#define VERSION_MAJOR $(VERSION_MAJOR)" >> tpm/tpm_version.h
- @echo "#define VERSION_MINOR $(VERSION_MINOR)" >> tpm/tpm_version.h
- @echo "#define VERSION_BUILD $(VERSION_BUILD)" >> tpm/tpm_version.h
- @echo "#endif /* _TPM_VERSION_H_ */" >> tpm/tpm_version.h
+version := tpm/tpm_version.h
+
+$(version):
+ @echo "#ifndef _TPM_VERSION_H_" > $@
+ @echo "#define _TPM_VERSION_H_" >> $@
+ @echo "#define VERSION_MAJOR $(VERSION_MAJOR)" >> $@
+ @echo "#define VERSION_MINOR $(VERSION_MINOR)" >> $@
+ @echo "#define VERSION_BUILD $(VERSION_BUILD)" >> $@
+ @echo "#endif /* _TPM_VERSION_H_ */" >> $@
clean: clean-recursive
- rm -f tpm/tpm_version.h
+ rm -f $(version)
install: install-recursive
-all-recursive clean-recursive install-recursive:
+all-recursive clean-recursive install-recursive: $(version)
@target=`echo $@ | sed s/-recursive//`; \
for subdir in $(SUBDIRS); do \
echo "Making $$target in $$subdir"; \
$(MAKE) -C $$subdir $$target || exit -1; \
done
-user: version
+user: $(version)
@$(MAKE) -C tpmd all || exit -1
@$(MAKE) -C tddl all || exit -1
-modules: version
+modules: $(version)
@$(MAKE) -C tpmd_dev all || exit -1
user_install: user
@@ -62,5 +64,5 @@ dist: $(DISTSRC)
tar -chzf $(DISTDIR).tar.gz $(DISTDIR)
@rm -rf $(DISTDIR)
-.PHONY: all version clean install dist
+.PHONY: all clean install dist