Skip to content

Commit

Permalink
Add a macosx-framework variant for those macosx developers who prefer…
Browse files Browse the repository at this point in the history
… mono

to be installed as an actual system component (complete with symlinks for
the commands in /usr/bin).  I might as well also officially take over
maintainership of this since this port has mutated substantially since
I started hacking on it and any bugs that are found are my fault, not mww's.

git-svn-id: https://svn.macports.org/repository/macports/trunk/dports@7547 d073be05-634f-4543-b044-5fe20cf6d1d6
  • Loading branch information
Jordan K. Hubbard committed Jun 17, 2004
1 parent bfbfc8e commit 9731c45
Showing 1 changed file with 26 additions and 5 deletions.
31 changes: 26 additions & 5 deletions devel/mono/Portfile
@@ -1,11 +1,11 @@
# $Id: Portfile,v 1.23 2004/06/17 03:38:19 jkh Exp $
# $Id: Portfile,v 1.24 2004/06/17 08:08:20 jkh Exp $

PortSystem 1.0
name mono
version 0.96
categories devel
platforms darwin
maintainers mww@opendarwin.org
maintainers jkh@opendarwin.org
description Implementation of the .NET Development Framework
long_description Mono is an effort to create an open source \
implementation of the .NET Development Framework \
Expand All @@ -22,14 +22,21 @@ depends_lib bin:pkg-config:pkgconfig \
lib:libicui18n:icu

configure.env CPPFLAGS="-I${prefix}/include" \
LDFLAGS="-L${prefix}/lib"
LDFLAGS="-L${prefix}/lib" \
ACLOCAL_FLAGS="-I ${prefix}/share/aclocal" \
PKG_CONFIG_PATH=${prefix}/lib/pkgconfig:${x11prefix}/lib/pkgconfig
configure.args --with-gc=included --enable-threads=pthreads

destroot.destdir DESTDIR=${destroot}
destroot.destdir DESTDIR=${destroot}
destroot.env DYLD_LIBRARY_PATH=${worksrcpath}/mono/mini/.libs:${worksrcpath}/mono/interpreter/.libs:/opt/local/lib:${x11prefix}/lib

variant darwin {
configure.args-append --without-sigaltstack
destroot.env DYLD_LIBRARY_PATH=${worksrcpath}/mono/mini/.libs:${worksrcpath}/mono/interpreter/.libs
}

# Build as a framework
variant macosx-framework requires darwin {
prefix /Library/Frameworks/Mono.framework/Versions/${version}
}

post-destroot {
Expand All @@ -42,4 +49,18 @@ post-destroot {
${worksrcpath}/COPYING.LIB ${worksrcpath}/ChangeLog \
${worksrcpath}/NEWS ${worksrcpath}/README \
${destroot}${prefix}/share/doc/${name}
if {[variant_isset macosx-framework]} {
cd ${destroot}/Library/Frameworks/Mono.Framework/Versions
system "ln -s ${version} Current"
cd ..
system "ln -s Versions/Current/lib Libraries"
system "ln -s Versions/Current/include Headers"
system "ln -s Versions/Current/bin Commands"
file mkdir ${destroot}/usr/bin
cd Commands
foreach binfile [glob *] {
if {[string match *.exe ${binfile}]} continue
system "ln -s /Library/Frameworks/Mono.Framework/Commands/${binfile} ${destroot}/usr/bin/${binfile}"
}
}
}

0 comments on commit 9731c45

Please sign in to comment.