diff --git a/Makefile.shared b/Makefile.shared index 19288ad..2ccb8e7 100644 --- a/Makefile.shared +++ b/Makefile.shared @@ -49,9 +49,10 @@ endef # Query the spec file (or spec files) listed in argument 2 for the field(s) # specified in argument 1. The fields are derived from the source rpm(s) -# generated by the specs. +# generated by the specs. Queried fields that are declared within the spec file +# must be declared above the first %files section. define queryspec -rpmspec --define='_vendor clr' --srpm --query --queryformat='$(1)' $(2) +rpmspec --define='_vendor clr' --srpm --query --queryformat='$(1)' <(sed -n '1,/%files/p' $(2)) endef # If GITOLITE_BASE_URL is defined, sets a repo's push URL for that gitolite