Skip to content

Commit

Permalink
mlton: update to 2024.12.30
Browse files Browse the repository at this point in the history
  • Loading branch information
barracuda156 committed Dec 31, 2024
1 parent 57cf56f commit 4202e78
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 42 deletions.
16 changes: 8 additions & 8 deletions lang/mlton/Portfile
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ PortGroup github 1.0
PortGroup makefile 1.0
PortGroup openssl 1.0

github.setup MLton mlton 475cf2b14993869711f1a93a15a9fa854b5126ed
version 20240519
revision 1
github.setup MLton mlton 74673d4e7de936497f74569a1145857d35261393
version 20241230
revision 0
categories lang ml
maintainers {@barracuda156 gmail.com:vital.had} openmaintainer
license HPND
Expand All @@ -21,14 +21,14 @@ long_description MLton is a whole-program optimizing compiler for the Standar
a complete implementation of the Standard ML Basis Library, various useful libraries, a simple and fast C foreign function interface, \
the ML Basis system for programming with source libraries, and tools such as a lexer generator, a parser generator and a profiler.
homepage http://www.mlton.org
checksums rmd160 37e2f94ad4b9934a29374587bfb75f98663691cf \
sha256 4b967f3826b1e697dd7655d29fa91fbe110c63f22781d6bcf3c6a2cfd15bfcbb \
size 14381913
checksums rmd160 eabb149f62c14284099047c76f9c6d5dca7c5185 \
sha256 8f8d5bdf1961385eecbacc807820fb8e5c0504cdf4240ab8ed1fcbfbf4fddbad \
size 14423203
github.tarball_from archive

depends_build-append \
port:bash \
port:git \
path:bin/git:git \
port:grep \
port:gsed \
port:mlton-bootstrap \
Expand All @@ -52,7 +52,7 @@ compiler.blacklist-append {clang < 900}
# We have to ensure that both mlton-bootstrap and mlton use the identical compiler.
# For now set it to use clang-16 or gcc-13. When newer compilers are enabled,
# it should be done for mlton-bootstrap and mlton together, with revbumping both.
compiler.blacklist-append {macports-clang-1[7-9]} {macports-gcc-1[4-9]}
compiler.blacklist-append {macports-clang-1[7-9]} {macports-gcc-1[5-9]}

build.args-append CC=${configure.cc} \
GMP_DIR=${prefix}
Expand Down
56 changes: 22 additions & 34 deletions lang/mlton/files/patch-settings-for-Macports.diff
Original file line number Diff line number Diff line change
@@ -1,13 +1,11 @@
From 53d12fe9ff77fd96a8973e8ff459b498ba728f9b Mon Sep 17 00:00:00 2001
From: barracuda156 <[email protected]>
Date: Fri, 21 Jul 2023 13:35:34 +0800
Subject: [PATCH 1/4] Amend Makefile.config for Macports
Subject: [PATCH] Amend Makefile.config for Macports

diff --git Makefile.config Makefile.config
index bc2cb5eef..204751d77 100644
--- Makefile.config
+++ Makefile.config
@@ -22,7 +22,7 @@ WITH_GMP_LIB_DIR := $(WITH_GMP_DIR)/lib
--- Makefile.config 2024-12-30 19:51:36.000000000 +0800
+++ Makefile.config 2024-12-31 02:54:22.000000000 +0800
@@ -22,7 +22,7 @@
endif

# Specify installation prefix and staged install destination.
Expand All @@ -16,7 +14,7 @@ index bc2cb5eef..204751d77 100644
DESTDIR :=

# Specify runtime and compile arguments given to (the to-be-built) `mlton`
@@ -41,7 +41,7 @@ OLD_MLTON := mlton
@@ -41,7 +41,7 @@
OLD_MLTON_RUNTIME_ARGS :=
OLD_MLTON_COMPILE_ARGS :=

Expand All @@ -25,7 +23,7 @@ index bc2cb5eef..204751d77 100644
ifneq (,$(OLD_MLTON_DIR))
OLD_MLTON := $(OLD_MLTON_DIR)/$(OLD_MLTON)
endif
@@ -50,12 +50,12 @@ endif
@@ -50,17 +50,17 @@
# Can be used for alternative tools (e.g., `SED=gsed`).
DIFF := diff
FIND := find
Expand All @@ -42,12 +40,26 @@ index bc2cb5eef..204751d77 100644
TAR := tar

SHA1SUM := sha1sum

SHA1 := sha1
-OPENSSL := openssl
+OPENSSL := @PREFIX@/bin/openssl
SHASUM := shasum

CAT := cat
@@ -85,7 +85,7 @@
MLTON_NAME := MLton [$(MLTON_FORK)]
endif
MLTON_OUTPUT := $(MLTON)-compile
-MLTON_VERSION := $(shell TZ=UTC $(GIT) log -n1 --date=format-local:"%Y%m%d.%H%M%S" --pretty=format:"%cd-g%h$$([ "$$($(GIT) status --porcelain 2> /dev/null)" ] && echo '-dirty')" 2> /dev/null || echo '????????')
+MLTON_VERSION := "@VERSION@"

######################################################################
######################################################################

From 106fc161be1c269db996acd207296385dcee1be5 Mon Sep 17 00:00:00 2001
From: barracuda156 <[email protected]>
Date: Fri, 21 Jul 2023 13:37:14 +0800
Subject: [PATCH 2/4] mlbdeps: amend for Macports
Subject: [PATCH] mlbdeps: amend for Macports

diff --git bin/mlbdeps bin/mlbdeps
index ef75768d0..abb885507 100755
Expand All @@ -62,27 +74,3 @@ index ef75768d0..abb885507 100755

name=$(basename "$0")


From 007c3ea9cd8b4e5ac46a333809ebf03abcc36b84 Mon Sep 17 00:00:00 2001
From: barracuda156 <[email protected]>
Date: Fri, 21 Jul 2023 22:55:53 +0800
Subject: [PATCH 4/4] Add version

---
Makefile.config | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git Makefile.config Makefile.config
index 204751d77..b714ebb4a 100644
--- Makefile.config
+++ Makefile.config
@@ -85,7 +85,7 @@ MLTON := mlton-$(MLTON_FORK)
MLTON_NAME := MLton [$(MLTON_FORK)]
endif
MLTON_OUTPUT := $(MLTON)-compile
-MLTON_VERSION := $(shell TZ=UTC $(GIT) log -n1 --date=format-local:"%Y%m%d.%H%M%S" --pretty=format:"%cd-g%h$$([ "$$($(GIT) status --porcelain 2> /dev/null)" ] && echo '-dirty')" 2> /dev/null || echo '????????')
+MLTON_VERSION := "@VERSION@"

######################################################################
######################################################################
--

0 comments on commit 4202e78

Please sign in to comment.