|
|
|
|
|
|
|
|
|
|
xen-api
[Xen-API] [PATCH] fix source manifest generation in xen-api-libs.hg
# HG changeset patch
# User David Scott <dave.scott@xxxxxxxxxxxxx>
# Date 1278920008 -3600
# Node ID ad151dc6eb4578f098df793e92498a9ba1a9ec3a
# Parent 7762ee00b89dfc4dbbd561453db5e75be36f5812
Fix the source manifest generation by using a simple shell script to scan the
SRPMS, rather than a hideous make/shell fragment.
Signed-off-by: David Scott <dave.scott@xxxxxxxxxxxxx>
diff -r 7762ee00b89d -r ad151dc6eb45 mk/Makefile
--- a/mk/Makefile Thu Jul 08 16:49:16 2010 +0100
+++ b/mk/Makefile Mon Jul 12 08:33:28 2010 +0100
@@ -26,10 +26,7 @@
$(MY_SOURCES)/MANIFEST: $(MY_SOURCES_DIRSTAMP)
rm -f $@
- @for srpm in "$(/bin/ls -1 ${MY_OUTPUT_DIR}/SRPMS)"; do \
- path=$(MY_OUTPUT_DIR)/SRPMS/${srpm}; \
- echo "$(${RPM} --qf "%{name}" -qp ${path}) $(${RPM} --qf
"%{License}" -qp ${path}) ${path}" >>$@; \
- done
+ /bin/sh ./srpms-to-manifest api-libs $(MY_OUTPUT_DIR)/SRPMS > $@
.PHONY: clean
rm -f *.rpm
diff -r 7762ee00b89d -r ad151dc6eb45 mk/srpms-to-manifest
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/mk/srpms-to-manifest Mon Jul 12 08:33:28 2010 +0100
@@ -0,0 +1,16 @@
+#!/bin/bash
+
+# take a component and a directory as arguments, write to stdout a
+# MANIFEST file fragment
+if [ -z "${RPM}" ]; then
+ RPM=/bin/rpm
+fi
+
+component=$1
+dir=$2
+for path in $(/bin/ls -1 $2/*.src.rpm); do
+ name=$(${RPM} --qf "%{name}" -qp ${path})
+ license=$(${RPM} --qf "%{License}" -qp ${path})
+ license=$(echo ${license} | /bin/sed -e 's/\s/_/g')
+ echo "${component} ${license} file ${path}"
+done
mk/Makefile | 5 +----
mk/srpms-to-manifest | 16 ++++++++++++++++
2 files changed, 17 insertions(+), 4 deletions(-)
xen-api-libs.hg.patch
Description: Text Data
_______________________________________________
xen-api mailing list
xen-api@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/mailman/listinfo/xen-api
|
<Prev in Thread] |
Current Thread |
[Next in Thread> |
- [Xen-API] [PATCH] fix source manifest generation in xen-api-libs.hg,
David Scott <=
|
|
|
|
|