- fix builds where /etc/profile.d doesn't exist
authorMichael Schröder <mls@suse.de>
Tue, 23 Dec 2008 11:07:45 +0000 (11:07 +0000)
committerMichael Schröder <mls@suse.de>
Tue, 23 Dec 2008 11:07:45 +0000 (11:07 +0000)
build

diff --git a/build b/build
index 2e50eab..b3d76a4 100755 (executable)
--- a/build
+++ b/build
@@ -1153,7 +1153,9 @@ for SPECFILE in "${SPECFILES[@]}" ; do
 
     # nasty hack to prevent rpath on known paths
     # FIXME: do this only for suse
-    echo "export SUSE_IGNORED_RPATHS=/etc/ld.so.conf" > "$BUILD_ROOT"/etc/profile.d/buildsystem.sh
+    if test -d "$BUILD_ROOT/etc/profile.d" ; then
+       echo "export SUSE_IGNORED_RPATHS=/etc/ld.so.conf" > "$BUILD_ROOT/etc/profile.d/buildsystem.sh"
+    fi
 
     #
     # now clean up RPM building directories