2005-12-07 Lluis Sanchez Gual <lluis@novell.com>
[mono.git] / scripts / mono-find-requires.in
index 46c939ef97068305a4668a2c7a5b9681f1aa064c..446d9fcfd2da452347b4bf3c8a7340dff66bb6e9 100644 (file)
@@ -12,12 +12,15 @@ IFS=$'\n'
 filelist=($(grep -Ev '/usr/doc/|/usr/share/doc/'))
 monolist=($(printf "%s\n" "${filelist[@]}" | egrep "\\.(exe|dll)\$"))
 
+a=`which "$0"`
+d=`dirname "$a"`
+
 # Set the prefix, unless it is overriden (used when building mono rpms)
-: ${prefix=@prefix@}
+: ${prefix=$d/..}
 
-exec_prefix=@exec_prefix@
-libdir=@libdir@
-bindir=@bindir@
+exec_prefix=$d/..
+libdir=$prefix/@reloc_libdir@
+bindir=$d
 
 [ -x $bindir/monodis ] || exit 0;
 [ -f $libdir/libmono.so ] || exit 0;