Skip to content

Commit

Permalink
PKG: copy Portfile from upstream
Browse files Browse the repository at this point in the history
  • Loading branch information
slivingston committed Mar 28, 2024
1 parent 62c5efb commit 5230cbc
Showing 1 changed file with 28 additions and 26 deletions.
54 changes: 28 additions & 26 deletions packaging/macports/Portfile
Original file line number Diff line number Diff line change
@@ -1,14 +1,16 @@
# -*- 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
PortGroup github 1.0

name gr1c
version 0.6.5
categories math devel
github.setup tulip-control gr1c 0.13.2 v

categories math devel
platforms darwin
maintainers {cds.caltech.edu:slivingston @slivingston} \
openmaintainer
license BSD
maintainers cds.caltech.edu:slivingston

description Tools for GR(1) synthesis and related activities

long_description A collection of tools for GR(1) synthesis and related \
Expand All @@ -17,33 +19,33 @@ long_description A collection of tools for GR(1) synthesis and related \
specifications, though it does much more.

homepage http://scottman.net/2012/gr1c
master_sites http://vehicles.caltech.edu/snapshots/gr1c/
platforms darwin
supported_archs i386 x86_64

checksums rmd160 9d3f4eb46a82f5f61b0459706639928a6a36b951 \
sha256 3c0daf15c7f0c243be7b99cea0618d3e11ff94c374ecbd5a1b31c8ac97455005
checksums rmd160 b5d45b6eccb6bd70b4e3d067b6e862488c97def0 \
sha256 48e43eb5790a32b59cb0f3528eedb1d40072730e6046541ff593e812ad26f506 \
size 191959

if {![string match "-arch x86_64" ${configure.cc_archflags}]
&& ![string match "-arch ppc64" ${configure.cc_archflags}]} {
post-patch {
reinplace "s|-DSIZEOF_VOID_P=8 -DSIZEOF_LONG=8|-malign-double|g" ${worksrcpath}/Makefile
}
}
depends_build port:bison \
port:flex

depends_build port:bison port:flex
depends_lib port:libcudd
universal_variant no

use_configure no
configure.cmd true

build.args CUDD_INC="-I${prefix}/include/cudd" \
CUDD_LIB="-L${prefix}/lib/cudd -lcudd"
build.args prefix="${prefix}"

foreach arch ${configure.universal_archs} {
lappend merger_build_args(${arch}) \
CC='${configure.cc} -arch ${arch}' \
LD='ld -r -arch ${arch}'
}

if {(!${universal_possible} || ![variant_isset universal]) && [info exists merger_build_args(${build_arch})]} {
build.args-append $merger_build_args(${build_arch})
}

test.run yes
test.target check
test.args CUDD_INC="-I${prefix}/include/cudd" \
CUDD_LIB="-L${prefix}/lib/cudd -lcudd"
destroot {
xinstall -m 0755 -W ${worksrcpath} gr1c rg grpatch ${destroot}${prefix}/bin
}
test.args {*}${build.args}

destroot.target install
destroot.args {*}${build.args}

0 comments on commit 5230cbc

Please sign in to comment.