--- macfuse/Portfile.orig	2008-07-06 00:28:10.000000000 +0200
+++ macfuse/Portfile	2008-10-22 16:31:56.000000000 +0200
@@ -61,17 +61,17 @@
     # we know the build script generates a .tar.bz2 right next to the dmg
     set tarname [string tolower [string replace $dmgname end-2 end "tar.bz2"]]
     system "tar -xjf $tarname -C ${destpath}"
-    delete ${destpath}/opt
-    file rename ${destpath}/usr ${destpath}/opt
+    delete ${destpath}${prefix}
+    file rename ${destpath}/usr/local ${destpath}${prefix}
     foreach f [list "pkgconfig/fuse.pc" "libfuse.la" "libulockmgr.la"] {
-        set path "${destpath}/opt/local/lib/${f}"
-        reinplace s,/usr/local,/opt/local, $path
+        set path "${destpath}${prefix}/lib/${f}"
+        reinplace s,/usr/local,${prefix}, $path
     }
     foreach lib [list "libulockmgr.1" "libfuse.2"] {
-        set libpath "/opt/local/lib/${lib}.dylib"
+        set libpath "${prefix}/lib/${lib}.dylib"
         system "install_name_tool -id ${libpath} ${destpath}${libpath}"
     }
-    system "install_name_tool -change /usr/local/lib/libfuse.2.dylib /opt/local/lib/libfuse.2.dylib ${destpath}/Library/Frameworks/MacFUSE.framework/Versions/A/MacFUSE"
+    system "install_name_tool -change /usr/local/lib/libfuse.2.dylib ${prefix}/lib/libfuse.2.dylib ${destpath}/Library/Frameworks/MacFUSE.framework/Versions/A/MacFUSE"
     # delete the whole directory the build script creates
     # when updating this Portfile DOUBLE CHECK THIS LINE
     delete [file dirname $dmgname]
