rpmdist.mk: Fix rpm copying into $(TOPDIR)

Fix builds aborted when generated rpms are copied back into working
dir.

Signed-off-by: Jan Lindemann <jan@janware.com>
This commit is contained in:
Jan Lindemann 2014-04-27 14:41:35 +00:00
commit 00db3a92e3
2 changed files with 10 additions and 5 deletions

View file

@ -53,3 +53,8 @@ SYMBOLS: $(LIB_A)
check_symversion:
$(symversion) | diff SYMBOLS - | sed '/^</ !d'
blah:
@echo RPM_VERSION = $(RPM_VERSION)
@echo DIST_VERSION = $(DIST_VERSION)

View file

@ -133,11 +133,11 @@ cpfiles.dist: src-dir.dist $(LOCAL_MKSPEC_SH)
$(DIST_PCKG_SRPM): $(DIST_PCKG_DIR)/$(PCKG_TAR)
$(RPMBUILD) -ts $<
cp $(SRPMS_DIR)/$(notdir $@) $@
cp $(SRPMS_DIR)/$(PCKG_RPM_SRC) $(dir $@)/
$(DIST_PCKG_RPM): $(DIST_PCKG_DIR)/$(PCKG_TAR)
if [ $< -nt $(RPMS_DIR)/$(notdir $@) ]; then $(RPMBUILD) -tb $<; fi
cp $(RPMS_DIR)/$(notdir $@) $@
cp $(RPMS_DIR)/$(PCKG_RPM_RUN_I386) $(dir $@)/
$(DIST_PCKG_DIR)/CURRENT_%: $(TOPDIR)/VERSION
echo $(CURRENT_$*) > $@
@ -251,9 +251,9 @@ rpm-check-release:
fi
rpm-release: rpm-update-release
@if [ "$(LAST_RPM_VERSION)" != "$(RPM_VERSION)" ]; then \
@if ! grep -q "^$(LAST_RPM_VERSION)\$" VERSION; then \
$(check_cvs_sync) ;\
echo "+ version $(RPM_VERSION) doesn't match latest relea$(SED) rpm version "\
echo "+ version $(RPM_VERSION) doesn't match latest released rpm version "\
"$(LAST_RPM_VERSION), building a new release" ;\
make rpm-clean update-repo.dist || exit 1;\
cp VERSION $(LAST_RPM_VERSION_FILE) ;\
@ -262,7 +262,7 @@ rpm-release: rpm-update-release
fi ;\
cvs commit -m "o `$(CAT) $(LAST_RPM_VERSION_FILE)`" $(LAST_RPM_VERSION_FILE) ;\
else \
echo "+ version matches latest relea$(SED) rpm version" ;\
echo "+ version matches latest released rpm version" ;\
fi
# doesn't work