1
0
Fork 0

Compare commits

...

3 Commits

Author SHA1 Message Date
retropikzel 168d749d6d Kawa fixes 2025-11-26 19:16:49 +02:00
retropikzel dfc62511d7 Kawa fixes 2025-11-26 18:13:55 +02:00
retropikzel f53b64dd01 Add --debug flag. Fix bash-completion. Small guile fixes 2025-11-26 18:09:19 +02:00
3 changed files with 15 additions and 16 deletions

View File

@ -18,7 +18,7 @@ _compile_scheme()
#if [[ "$i" == "-t" ]] ; then #if [[ "$i" == "-t" ]] ; then
#targetfound=true #targetfound=true
#fi #fi
done #done
if [[ "$outputfound" == "false" ]]; then if [[ "$outputfound" == "false" ]]; then
shortopts="${shortopts} -o" shortopts="${shortopts} -o"

View File

@ -8,6 +8,8 @@
(libs library-util) (libs library-util)
(srfi 170)) (srfi 170))
(define debug? (if (member "--debug" (command-line)) #t #f))
(when (member "--help" (command-line)) (when (member "--help" (command-line))
(display "For help see: man compile-scheme") (display "For help see: man compile-scheme")
(newline) (newline)
@ -204,6 +206,11 @@
r6rs? r6rs?
compilation-target))) compilation-target)))
(when debug?
(display "[debug] scheme-command: ")
(write scheme-command)
(newline))
(define scheme-library-command (define scheme-library-command
(lambda (library-file) (lambda (library-file)
(apply (cdr (assoc 'library-command (cdr (assoc scheme data)))) (apply (cdr (assoc 'library-command (cdr (assoc scheme data))))

View File

@ -282,8 +282,7 @@
,(util-getenv "COMPILE_R7RS_GUILE") ,(util-getenv "COMPILE_R7RS_GUILE")
,(if r6rs? " --r6rs -x .sls " " --r7rs -x .sld ") ,(if r6rs? " --r6rs -x .sls " " --r7rs -x .sld ")
,@(map (lambda (item) ,@(map (lambda (item)
(string-append " -L " item " " (string-append " -L " item " "))
" -L " (dirname item) " "))
(append prepend-directories (append prepend-directories
append-directories)) append-directories))
" -s " " -s "
@ -353,24 +352,17 @@
r6rs? r6rs?
compilation-target) compilation-target)
(apply string-append (apply string-append
`("CLASSPATH=" `(,exec-cmd
,@(map (lambda (item) " kawa -J--add-exports=java.base/jdk.internal.foreign.abi=ALL-UNNAMED -J--add-exports=java.base/jdk.internal.foreign.layout=ALL-UNNAMED -J--add-exports=java.base/jdk.internal.foreign=ALL-UNNAMED -J--enable-native-access=ALL-UNNAMED -J--enable-preview --full-tailcalls"
(if (char=? (string-ref item 0) #\/)
(string-append item ":")
(string-append pwd "/" item ":")))
(append prepend-directories
append-directories))
" "
,exec-cmd
" kawa -J--add-exports=java.base/jdk.internal.foreign.abi=ALL-UNNAMED -J--add-exports=java.base/jdk.internal.foreign.layout=ALL-UNNAMED -J--add-exports=java.base/jdk.internal.foreign=ALL-UNNAMED -J--enable-native-access=ALL-UNNAMED -J--enable-preview "
,(util-getenv "COMPILE_R7RS_KAWA") ,(util-getenv "COMPILE_R7RS_KAWA")
" -Dkawa.import.path=" " -Dkawa.import.path="
,@(map (lambda (item) ,@(map (lambda (item)
(if (char=? (string-ref item 0) #\/) (if (char=? (string-ref item 0) #\/)
(string-append item "/*.sld") (string-append item "/*.sld:")
(string-append pwd "/" item "/*.sld"))) (string-append pwd "/" item "/*.sld:")))
(append prepend-directories (append prepend-directories
append-directories)) append-directories
(list "/usr/local/share/kawa/lib")))
" -f " " -f "
,script-file ,script-file
" " " "