From 1a388281f524ea046302e574bf981d1542f09d30 Mon Sep 17 00:00:00 2001 From: Will Andrews Date: Thu, 27 Jun 2002 14:32:30 +0000 Subject: Add qscheme 0.5.1, a small and fast Scheme interpreter. PR: 34999 Submitted by: erik@smluc.org --- lang/qscheme/files/patch-Makefile.in | 11 ++++ lang/qscheme/files/patch-configure | 103 +++++++++++++++++++++++++++++++++++ lang/qscheme/files/patch-s.h | 11 ++++ lang/qscheme/files/patch-s.scm | 30 ++++++++++ 4 files changed, 155 insertions(+) create mode 100644 lang/qscheme/files/patch-Makefile.in create mode 100644 lang/qscheme/files/patch-configure create mode 100644 lang/qscheme/files/patch-s.h create mode 100644 lang/qscheme/files/patch-s.scm (limited to 'lang/qscheme/files') diff --git a/lang/qscheme/files/patch-Makefile.in b/lang/qscheme/files/patch-Makefile.in new file mode 100644 index 000000000000..6bffee35418c --- /dev/null +++ b/lang/qscheme/files/patch-Makefile.in @@ -0,0 +1,11 @@ +--- Makefile.in.orig Sun Feb 10 12:52:32 2002 ++++ Makefile.in Sun Feb 10 12:52:37 2002 +@@ -111,7 +111,7 @@ + EXTRA_DIST = mkoptable mkwhatis $(modsrc) $(scmsrc) CHANGES LICENCE_EXCEPTION + + # other directories +-SUBDIRS = . doc sgtk ++SUBDIRS = . doc + + noinst_LIBRARIES = libqs.a + diff --git a/lang/qscheme/files/patch-configure b/lang/qscheme/files/patch-configure new file mode 100644 index 000000000000..e639d2ff9386 --- /dev/null +++ b/lang/qscheme/files/patch-configure @@ -0,0 +1,103 @@ +--- configure.orig Thu Jun 22 06:09:24 2000 ++++ configure Sun Feb 10 12:51:27 2002 +@@ -1288,55 +1288,6 @@ + rm -fr conftest* + fi + +- +-echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6 +-echo "configure:1294: checking for dlopen in -ldl" >&5 +-ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'` +-if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then +- echo $ac_n "(cached) $ac_c" 1>&6 +-else +- ac_save_LIBS="$LIBS" +-LIBS="-ldl $LIBS" +-cat > conftest.$ac_ext <&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then +- rm -rf conftest* +- eval "ac_cv_lib_$ac_lib_var=yes" +-else +- echo "configure: failed program was:" >&5 +- cat conftest.$ac_ext >&5 +- rm -rf conftest* +- eval "ac_cv_lib_$ac_lib_var=no" +-fi +-rm -f conftest* +-LIBS="$ac_save_LIBS" +- +-fi +-if eval "test \"`echo '$ac_cv_lib_'$ac_lib_var`\" = yes"; then +- echo "$ac_t""yes" 1>&6 +- ac_tr_lib=HAVE_LIB`echo dl | sed -e 's/[^a-zA-Z0-9_]/_/g' \ +- -e 'y/abcdefghijklmnopqrstuvwxyz/ABCDEFGHIJKLMNOPQRSTUVWXYZ/'` +- cat >> confdefs.h <&6 +-{ echo "configure: error: needs libdl" 1>&2; exit 1; } +-fi +- + echo $ac_n "checking for atan in -lm""... $ac_c" 1>&6 + echo "configure:1342: checking for atan in -lm" >&5 + ac_lib_var=`echo m'_'atan | sed 'y%./+-%__p_%'` +@@ -1385,14 +1336,14 @@ + { echo "configure: error: needs libm" 1>&2; exit 1; } + fi + +-echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6 +-echo "configure:1390: checking for pthread_create in -lpthread" >&5 ++echo $ac_n "checking for pthread_create in -pthread""... $ac_c" 1>&6 ++echo "configure:1390: checking for pthread_create in -pthread" >&5 + ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'` + if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then + echo $ac_n "(cached) $ac_c" 1>&6 + else + ac_save_LIBS="$LIBS" +-LIBS="-lpthread $LIBS" ++LIBS="-pthread $LIBS" + cat > conftest.$ac_ext <&6 +@@ -2485,7 +2436,7 @@ + ac_given_srcdir=$srcdir + ac_given_INSTALL="$INSTALL" + +-trap 'rm -fr `echo "Makefile tst/Makefile doc/Makefile sgtk/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 ++trap 'rm -fr `echo "Makefile tst/Makefile doc/Makefile config.h" | sed "s/:[^ ]*//g"` conftest*; exit 1' 1 2 15 + EOF + cat >> $CONFIG_STATUS <> $CONFIG_STATUS <> $CONFIG_STATUS <<\EOF + for ac_file in .. $CONFIG_FILES; do if test "x$ac_file" != x..; then diff --git a/lang/qscheme/files/patch-s.h b/lang/qscheme/files/patch-s.h new file mode 100644 index 000000000000..984d85b343ed --- /dev/null +++ b/lang/qscheme/files/patch-s.h @@ -0,0 +1,11 @@ +--- s.h.orig Sun Feb 10 12:45:20 2002 ++++ s.h Sun Feb 10 12:45:32 2002 +@@ -203,7 +203,7 @@ + + #ifdef SCM_WITH_THREADS + /*** same as in Boehm's GC */ +-#define SCM_SIG_SUSPEND SIGPWR ++#define SCM_SIG_SUSPEND SIGUSR1 + #define SCM_SIG_RESUME SIGXCPU + #endif + diff --git a/lang/qscheme/files/patch-s.scm b/lang/qscheme/files/patch-s.scm new file mode 100644 index 000000000000..9d987fc3dcd0 --- /dev/null +++ b/lang/qscheme/files/patch-s.scm @@ -0,0 +1,30 @@ +--- s.scm.orig Thu Dec 6 04:56:07 2001 ++++ s.scm Thu Dec 6 04:56:26 2001 +@@ -252,7 +252,26 @@ + (define hset! hash-set!) + + ; General purpose functions +-(load "sgtk/defextern.scm") ++;(load "sgtk/defextern.scm") ++ ++(define *lib* "") ++ ++(define-macro (extern type name . args) ++ `(make-extfunc *lib* ,type ,(symbol->string name) (quote ,@args))) ++ ++; simplified exteral declarator: ++; ++; (define-extern :RETURN-TYPE CFUNC-NAME :ARG1 :ARG2... [. :ANY]) ++; ++(define (cname->scheme x) ++ (string->symbol (string-translate (symbol->string x) "_" "-"))) ++ ++(define-macro (define-extern t n . a) ++; (write ++ `(define ,(cname->scheme n) ++ (make-extfunc *lib* ,t ,(symbol->string n) (quote ,a)))) ++; ) ++ + + ;; (load "repl.scm") + -- cgit v1.2.3