Skip to content

Commit

Permalink
ragel: update to 7.0.4
Browse files Browse the repository at this point in the history
  • Loading branch information
barracuda156 authored and kencu committed Oct 30, 2022
1 parent c0a43a1 commit cd2c9d0
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 10 deletions.
39 changes: 29 additions & 10 deletions lang/ragel/Portfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,13 @@
# -*- 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

PortSystem 1.0
PortGroup github 1.0

name ragel
version 7.0.0.12
# Please keep commit-based set-up until next release
github.setup adrian-thurston ragel d4577c924451b331c73c8ed0af04f6efd35ac0b4
version 7.0.4
revision 0
categories lang devel
platforms darwin
license MIT

maintainers nomaintainer
Expand All @@ -21,14 +22,32 @@ long_description Ragel compiles executable finite state machines from \
language.

homepage http://www.colm.net/open-source/ragel/
master_sites http://www.colm.net/files/ragel/

checksums rmd160 39f37e804b9cc8b5a117350a5643791458c2b2b3 \
sha256 3999ef97fb108b39d11d9b96986f5e05c74bd95de8dd474301d86c5aca887a74 \
size 1543127
checksums rmd160 838fb6f2803e7c166f2a98ec4de8eaf9f0c9ad19 \
sha256 2208c0e2a4ec575f1e8bf27a0563f0bbf4afb3a28a97bed01c2376f1d75759a0 \
size 455645

depends_lib-append port:colm

livecheck.type regex
livecheck.url ${homepage}
livecheck.regex {ragel-(\d+(?:\.\d+)*).tar.gz}
patchfiles patch-lafiles.diff

use_autoconf yes
autoconf.cmd ./autogen.sh

depends_build-append \
port:autoconf \
port:automake \
port:libtool \
port:pkgconfig

configure.args-append \
--with-colm=${prefix}

configure.ldflags-append \
-L${prefix}/lib -lfsm

This comment has been minimized.

Copy link
@ryandesign

ryandesign Nov 1, 2022

Contributor

-L${prefix}/lib is in configure.ldflags by default; you don't need to add it a second time.


platform darwin 10 powerpc {
# Rosetta gets it wrong otherwise
configure.args-append \
--build=powerpc-apple-darwin${os.major}
}
41 changes: 41 additions & 0 deletions lang/ragel/files/patch-lafiles.diff
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# https://github.com/adrian-thurston/ragel/pull/85

--- configure.ac.orig 2021-12-29 04:19:46.000000000 +0800
+++ configure.ac 2022-10-08 06:19:57.000000000 +0800
@@ -47,13 +47,23 @@
CPPFLAGS="-I$withval/include ${CPPFLAGS}"
CPPFLAGS="-I$withval/include/aapl ${CPPFLAGS}"
LDFLAGS="-L$withval/lib ${LDFLAGS}"
- LIBCOLM_LA="$withval/lib/libcolm.la"
- LIBFSM_LA="$withval/lib/libfsm.la"
COLM_SHARE="$withval/share/colm"
],
[]
)

+AC_CHECK_LIB(
+ [colm],
+ [colm_run_program],
+ [LIBCOLM_LA=-lcolm],
+ [AC_ERROR([libcolm is required to build ragel])]
+)
+AC_CHECK_LIB(
+ [fsm],
+ [LIBFSM_LA=-lfsm],
+ [AC_ERROR([libfsm is required to build ragel])]
+)
+
AC_CHECK_FILES(
[$COLM],
[],

--- src/Makefile.am.orig 2021-12-29 04:19:46.000000000 +0800
+++ src/Makefile.am 2022-10-08 06:05:53.000000000 +0800
@@ -40,7 +40,6 @@
parse.c rlreduce.cc

ragel_LDADD = $(LIBFSM_LA) $(LIBCOLM_LA) libragel.la
-ragel_DEPENDENCIES = $(LIBFSM_LA) $(LIBCOLM_LA) libragel.la

BUILT_SOURCES = \
version.h \

0 comments on commit cd2c9d0

Please sign in to comment.