# -*- mode: tcl; coding: utf-8; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- # vim:fenc=utf-8:filetype=tcl:et:sw=4:ts=4:sts=4 # $Id: Portfile 153544 2016-10-04 08:03:12Z ryandesign@macports.org $ PortSystem 1.0 name sbcl # Please revbump ../../math/maxima when this port changes version 1.3.10 revision 0 categories lang license BSD maintainers easieste openmaintainer platforms darwin description The Steel Bank Common Lisp system long_description \ Steel Bank Common Lisp (SBCL) is a Open Source implementation of ANSI \ Common Lisp. It provides an interactive environment including an \ integrated native compiler, interpreter, and debugger. SBCL is quite \ suitable for the creation of long running system services, as the compiler \ trades the time for a long initial compilation for blazingly fast loading \ of its binary runtime fasl representation. homepage http://www.sbcl.org master_sites sourceforge:project/sbcl/sbcl/${version}:sbcl use_bzip2 yes # Removed with sbcl-1.3.10 to work on macOS 10.2 Sierra #patchfiles \ # patch-use-right-gcc.diff distfiles ${name}-${version}-source${extract.suffix}:sbcl worksrcdir ${name}-${version} checksums ${name}-${version}-source${extract.suffix} \ rmd160 bf453e2e4241436f811dcd567828640f13092b31 \ sha256 4a567aad91b316c22eb756dd8e502cfd9a95a4c660fb1fa2eb1e50e009b85777 platform powerpc { set bootversion 1.0.47 master_sites-append sourceforge:project/sbcl/sbcl/${bootversion}:sbcl_powerpc distfiles-append ${name}-${bootversion}-powerpc-darwin-binary${extract.suffix}:sbcl_powerpc checksums-append ${name}-${bootversion}-powerpc-darwin-binary${extract.suffix} \ md5 02747afc7631a7ccdeede4b52b78072d \ sha1 93df00b3120810a086d37666c1ccdeabc8daeb49 \ rmd160 85c76296a1c62db5affdff7e72e61e558bb5c819 global host_lisp set host_lisp "\"${workpath}/${name}-${bootversion}-powerpc-darwin/src/runtime/sbcl --core ${workpath}/${name}-${bootversion}-powerpc-darwin/output/sbcl.core --disable-debugger --sysinit /dev/null --userinit /dev/null\" " } platform i386 { set bootversion 1.0.55 master_sites-append sourceforge:project/sbcl/sbcl/${bootversion}:sbcl_i386 distfiles-append ${name}-${bootversion}-x86-darwin-binary${extract.suffix}:sbcl_i386 checksums-append ${name}-${bootversion}-x86-darwin-binary${extract.suffix} \ md5 941351112392a77dd62bdcb9fb62e4e4 \ sha1 8ea71938c40a6dccfe2d43a86e9b115f4428a218 \ rmd160 97c92e16426fb4e7eb9e649e21714c342703d17b global host_lisp set host_lisp "\"${workpath}/${name}-${bootversion}-x86-darwin/src/runtime/sbcl --core ${workpath}/${name}-${bootversion}-x86-darwin/output/sbcl.core --disable-debugger --sysinit /dev/null --userinit /dev/null\" " } post-patch { reinplace "s|/usr/local/lib/${name}|${prefix}/lib/${name}|g" \ ${worksrcpath}/doc/sbcl.1 # # This change is required as the Xcode 8 linker now defaults to # PIE binaries regardless of the deployment target so an explicit # '-Wl,-no_pie' is now required. The rbcl program is incompatible # with ASLR and the previous upstream hack of setting the # deployment target to less than 10.7 doesn't prevent the PIE # executables from being created against the Xcode 8 # linker. Tested on 10.11 with Xcode 8 beta. if {[vercmp "8.0" ${xcodeversion}] >= 0} { reinplace "s|0x100000|0x100000 -Wl,-no_pie|g" ${worksrcpath}/src/runtime/Config.x86-64-darwin } } use_configure no build { reinplace s|CC=gcc|CC=${configure.cc}| ${worksrcpath}/contrib/asdf-module.mk system "ulimit -s 8192 && unset LD_PREBIND && unset LD_PREBIND_ALLOW_OVERLAP && export SBCL_MACOSX_VERSION_MIN=10.5 && cd ${worksrcpath} && export CC && CC=${configure.cc} && export CXX && CXX=${configure.cxx} && export CPP && CPP==${configure.cpp} && sh ./make.sh ${make_sh_options} --prefix=${prefix} --xc-host=${host_lisp}" } post-build { if {[variant_isset html] || [variant_isset pdf]} { system -W ${worksrcpath}/doc "INSTALL_ROOT=${destroot}${prefix} sh ${worksrcpath}/doc/make-doc.sh" } } if {![variant_isset threads]} { default_variants +fancy } variant html conflicts pdf description {Installs documentation in HTML and Info formats.} { patchfiles-append patch-make-doc.diff depends_build-append bin:texi2dvi:texinfo depends_build-append bin:makeinfo:texinfo } variant pdf conflicts html description {Installs documentation in PDF, HTML and Info formats. Involves the installation of a TexLive dependency chain, which can dramatically slow down the installation of the SBCL port.} { depends_build-append bin:dvips:texlive depends_build-append bin:texi2dvi:texinfo depends_build-append bin:makeinfo:texinfo } global make_sh_options set make_sh_options "" variant threads description {Enable multi-threaded runtime using the Mach pthreads interface.} { set make_sh_options --with-sb-thread } variant fancy conflicts threads description {Configure SBCL compilation with all available compatible options (including threading).} { set make_sh_options --fancy } test.run yes test.dir ${worksrcpath}/tests test.cmd CC=${configure.cc} CXX=${configure.cxx} CPP=${configure.cpp} sh test.target run-tests.sh destroot { system -W ${worksrcpath} "INSTALL_ROOT=${destroot}${prefix} sh ${worksrcpath}/install.sh" } livecheck.url http://sourceforge.net/api/file/index/project-id/1373/rss?path=%2F${name} livecheck.regex guid.*${name}-(\\d+(\\.\\d+)+)-source