# exit early on --version or --help
done=false
+# Currently this scripts depends on some RPM environment variables
+# being set. RPM_BUILD_ROOT as the installation root directory.
+# RPM_BUILD_DIR as the top build dir (usually one above BUILDDIR).
+# And RPM_PACKAGE_NAME, RPM_PACKAGE_VERSION, RPM_PACKAGE_RELEASE,
+# RPM_ARCH to create an unique (dir) name. Warn if they aren't set.
+if test -z "${RPM_BUILD_ROOT}"; then
+ echo "RPM_BUILD_ROOT not set"
+ exit 1;
+fi
+if test -z "${RPM_BUILD_DIR}"; then
+ echo "RPM_BUILD_DIR not set"
+ exit 1;
+fi
+if test -z "${RPM_PACKAGE_NAME}"; then
+ echo "RPM_PACKAGE_NAME not set"
+ exit 1;
+fi
+
BUILDDIR=.
out=debugfiles.list
srcout=