-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
54 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
https://github.com/termux/termux-packages/pull/20560#issuecomment-2171793305 | ||
|
||
--- a/Makefile.config | ||
+++ b/Makefile.config | ||
@@ -90,9 +90,8 @@ DATADIR ?= $(PREFIX)/share/cyclone | ||
DESTDIR ?= | ||
|
||
# Automatically detect platform-specific flags, instead of using autoconf | ||
-#CYC_PLATFORM_HAS_MEMSTREAM ?= 1 | ||
-CYC_PLATFORM_HAS_MEMSTREAM := $(shell echo "main(){char *buf; int len; open_memstream(&buf, &len);}" | $(CC) -xc - >/dev/null 2>/dev/null && echo 1 || echo 0) | ||
-CYC_PLATFORM_HAS_FMEMOPEN := $(shell echo "main(){char *buf; fmemopen(&buf, 0, \"r\");}" | $(CC) -xc - >/dev/null 2>/dev/null && echo 1 || echo 0) | ||
+CYC_PLATFORM_HAS_MEMSTREAM ?= 1 | ||
+CYC_PLATFORM_HAS_FMEMOPEN ?= 1 | ||
|
||
# code from chibi's makefile to detect platform | ||
ifndef PLATFORM |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
TERMUX_PKG_HOMEPAGE=http://justinethier.github.io/cyclone/ | ||
TERMUX_PKG_DESCRIPTION="A brand-new compiler that allows practical application development using R7RS Scheme" | ||
TERMUX_PKG_LICENSE="MIT" | ||
TERMUX_PKG_MAINTAINER="@termux" | ||
TERMUX_PKG_VERSION="0.36.0" | ||
TERMUX_PKG_SRCURL=https://github.com/justinethier/cyclone-bootstrap/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz | ||
TERMUX_PKG_SHA256=6b984f4cc336993306cfc3e6bd9e82f4fc1a008f3592d4e942b5de182f5fac20 | ||
TERMUX_PKG_DEPENDS="libandroid-complex-math, libck" | ||
TERMUX_PKG_AUTO_UPDATE=true | ||
TERMUX_PKG_BUILD_IN_SRC=true | ||
TERMUX_PKG_NO_STATICSPLIT=true | ||
TERMUX_PKG_BLACKLISTED_ARCHES="arm" ## follows `libck` blacklist | ||
TERMUX_PKG_EXTRA_MAKE_ARGS=" | ||
PREFIX=$TERMUX_PREFIX | ||
PLATFORM=android | ||
" | ||
|
||
termux_step_pre_configure() { | ||
CFLAGS+=" -I$TERMUX_PREFIX/include" # for gc.c | ||
CFLAGS+=" -Wno-error=int-conversion" # for i686 | ||
LDFLAGS+=" -lm -landroid-complex-math" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
--- a/include/cyclone/types.h | ||
+++ b/include/cyclone/types.h | ||
@@ -22,6 +22,13 @@ | ||
#include <dlfcn.h> | ||
#include "cyclone/bignum.h" | ||
|
||
+#if defined(__ANDROID__) && __ANDROID_API__ < 26 | ||
+double complex clog(double complex); | ||
+float complex clogf(float complex); | ||
+double complex cpow(double complex, double complex); | ||
+float complex cpowf(float complex, float complex); | ||
+#endif | ||
+ | ||
#ifdef CYC_HIGH_RES_TIMERS | ||
/** | ||
* \defgroup hrt High resolution timers |