From 6b75286ff98a3e23840d6fa699da1750234b8343 Mon Sep 17 00:00:00 2001 From: Federico Vaga <federico.vaga@cern.ch> Date: Tue, 22 Oct 2019 11:35:31 +0200 Subject: [PATCH] [sw] on RPM build just copy files Signed-off-by: Federico Vaga <federico.vaga@cern.ch> --- software/Makefile | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/software/Makefile b/software/Makefile index 00a56932..ee25bafd 100644 --- a/software/Makefile +++ b/software/Makefile @@ -34,10 +34,16 @@ dkms_install: $(eval $@_dst := $(shell mktemp -d)) @mkdir -p $($@_dst) @mkdir -p $(DST) +ifdef RPMBUILD +# We already did the file selection when producing the tar.gz +# Just copy + @cp -a $(GCORES)/* $(DST) +else @$(GIT) archive --format=tar -o $($@_dst)/$(DIR_NAME).tar --prefix=$(DIR_NAME)/ HEAD @cd $($@_dst) && tar -xf $(DIR_NAME).tar @mv $($@_dst)/$(DIR_NAME)/* $(DST) && rm -rf $($@_dst) @cp $(GCORES)/common.mk $(DST) +endif @sed -e '2,$$d' -i $(DST)/common.mk @sed -r -i -e "s/@PKGVER@/$(VERSION)/" $(DST)/dkms.conf @sed -e "15d" -e "6,13d" -e "23,26d" -e '33,$$d' \ -- GitLab