# -*- coding: utf-8; mode: tcl; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- vim:fenc=utf-8:ft=tcl:et:sw=4:ts=4:sts=4 # $Id$ PortSystem 1.0 name osxfuse version 2.6.2 categories fuse devel platforms macosx license BSD APSL maintainers dports openmaintainer description A FUSE-Compliant File System Implementation Mechanism \ for Mac OS X long_description FUSE for OS X implements a mechanism that makes it possible to implement \ a fully functional file system in a user-space program on Mac OS X. It \ aims to be API-compliant with the FUSE (File-system in USErspace) \ mechanism that originated on Linux. Therefore, many existing FUSE file \ systems become readily usable on Mac OS X. This port provides the \ user-space library and header files for building filesystems. homepage http://osxfuse.github.io/ distfiles set mp.dist { osxfuse 6423b85 {rmd160 015d1c3a82a1f90b3695bcac4e238583e7d34d65 sha256 f093a9d91c8a0d30902c2d203617876e16f3d12391fb878d6df9539da9c56555} kext 634518a {rmd160 562adbcae55b87065f347888f0068d564117d469 sha256 b0c4f0e6e1fe46799a0ac36cd05864df72304e50bd4954fd986d1a5626b7fd38} framework 5aa704c {rmd160 608c5f88d4f8178fbb2560244fe0effe62e70cc7 sha256 611e50f0e6dda47ac3cc1e88b2baa468c52eda6f6c1b6859fe29985184f48058} prefpane 226437b {rmd160 d66a6cf9c5703ab8768feedc65e8ff6ba61c78ea sha256 f8233ae4d1455365223e32a51d4f1d2a399d983f07b3c1efe9891f450a1a9828} fuse ca2210f {rmd160 ec2a232f416233e678d0687557873a12058cb012 sha256 2b9279cc5f0f4582fc4829c68b6c949a23f1118dfa5227de055a44c67f733415} support c5eb518 {rmd160 bcef5963e192d0651ae1c87042944387cdf562d1 sha256 da9076bf2da0cd6304b6fe4075ecfcca1fd398548d3c04159dd9225ea3c6a343} } set mp.osxfuse_rev [lindex ${mp.dist} [expr [lsearch ${mp.dist} osxfuse] + 1]] worksrcdir osxfuse-osxfuse-${mp.osxfuse_rev} foreach { mp.comp mp.rev mp.chksum } ${mp.dist} { set f ${mp.comp}-${mp.rev}.tar.gz master_sites-append https://github.com/osxfuse/${mp.comp}/tarball/${mp.rev}/:${mp.comp} distfiles-append ${f}:${mp.comp} checksums-append ${f} foreach {type chksum} ${mp.chksum} { checksums-append ${type} ${chksum} } } post-extract { foreach { mp.comp mp.rev mp.chksum } ${mp.dist} { if {${mp.comp} ne "osxfuse"} { # Replace existing empty directory if it exists file delete ${workpath}/${worksrcdir}/${mp.comp} move ${workpath}/osxfuse-${mp.comp}-${mp.rev} ${workpath}/${worksrcdir}/${mp.comp} } } } patchfiles patch-buildsystem.diff \ patch-kext-location.diff post-patch { # Perhaps the ports sandbox does not let us write to /tmp. # For a quick and temporary fix use this reinplace. file mkdir ${workpath}/tmp reinplace "s,@@TMP@@,${workpath}/tmp,g" ${worksrcpath}/build.sh # Only build the archs we want, not the hardcoded universal archs reinplace -E "s,@@ARCHS@@,[get_canonical_archs],g" ${worksrcpath}/build.sh # Inject the destroot path as the buildsystem tries to write to the prefix directly reinplace -E "s,@@DESTROOT@@,${destroot},g" ${worksrcpath}/build.sh # Correct the location of the kext reinplace -E "s,@@PREFIX@@,${prefix},g" ${worksrcpath}/kext/common/fuse_param.h } use_configure no build.cmd ./build.sh # Yes, they really named this target homebrew build.target -t homebrew build.args -f ${prefix} # The build step already does everything destroot {} # Move filesystem bundle into place post-destroot { # Set proper permissions fs-traverse f ${destroot}${prefix}/Library { file attributes $f -owner root -group wheel } # Enable setuid on helper binary file attributes ${destroot}${prefix}/Library/Filesystems/osxfusefs.fs/Support/load_osxfusefs -permissions 04755 } destroot.violate_mtree yes # FIXME: Add specific instructions how to unmount and reload kext notes { When upgrading, unmount all FUSE filesystems and then reload the kernel extension. If unsure how to do that, just reboot your computer now. } # Could probably be supported by setting ARCHS correctly above universal_variant no