Skip to main content

Indie game storeFree gamesFun gamesHorror games
Game developmentAssetsComics
SalesBundles
Jobs
TagsGame Engines

Hi I'm also having compilation errors:

>make

guild compile-wasm -L modules -o game.wasm game.scm

guile: warning: failed to install locale

warning: failed to install locale: Invalid argument

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/scripts/compile-wasm.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=0

;;;       or pass the --no-auto-compile argument to disable.

;;; compiling /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/scripts/compile-wasm.scm

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/compile.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; compiling /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/hoot/compile.scm

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/library-group.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/inline-wasm.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; compiling /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/hoot/inline-wasm.scm

;;; WARNING: compilation of /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/hoot/inline-wasm.scm failed:

;;; In procedure resolve-interface: no binding `add-primcall-effect-analyzer!' in module (language tree-il effects)

;;; WARNING: compilation of /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/hoot/compile.scm failed:

;;; In procedure resolve-interface: no binding `add-primcall-effect-analyzer!' in module (language tree-il effects)

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/backend.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; compiling /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/hoot/backend.scm

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/language/cps/hoot.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; compiling /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/language/cps/hoot.scm

;;; WARNING: compilation of /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/language/cps/hoot.scm failed:

;;; In procedure resolve-interface: no binding `primcall-raw-representations' in module (language cps utils)

;;; WARNING: compilation of /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/hoot/backend.scm failed:

;;; In procedure resolve-interface: no binding `primcall-raw-representations' in module (language cps utils)

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/stdlib.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/wat.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/types.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/dump.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/link.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/lower.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/lower-globals.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/lower-stringrefs.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/resolve.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: compilation of /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/share/guile/site/3.0/scripts/compile-wasm.scm failed:

;;; Syntax error:

;;; unknown location: definition in expression context, where definitions are not allowed, in form (define (maybe-branch-on-arity-mismatch checks) (if (null? checks) (quote ()) (branch-on-arity-mismatch checks)))

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/reflect.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/hoot/config.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/canonical-types.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/parse.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/vm.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/stack.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

;;; WARNING: loading compiled file /gnu/store/s8v5axydz2mvl65grbnszpis53njp7vb-profile/lib/guile/3.0/site-ccache/wasm/assemble.go failed:

;;; In procedure load-thunk-from-memory: incompatible bytecode version

Backtrace:

In ice-9/boot-9.scm:

  1752:10 10 (with-exception-handler _ _ #:unwind? _ # _)

In unknown file:

           9 (apply-smob/0 #<thunk 7fd71ae612e0>)

In ice-9/boot-9.scm:

    724:2  8 (call-with-prompt _ _ #<procedure default-prompt-handle?>)

In ice-9/eval.scm:

    619:8  7 (_ #(#(#<directory (guile-user) 7fd71ae66c80>)))

In /home/shakya/.guix-profile/bin/guild:

    72:17  6 (main _)

In ice-9/eval.scm:

    619:8  5 (_ #(#(#(#(#(#<directory (scripts compile-?> ?)) ?) ?) ?))

   293:34  4 (_ #(#(#(#(#(#<directory (scripts compile-?> ?)) ?) ?) ?))

In ice-9/boot-9.scm:

    152:2  3 (with-fluid* _ _ _)

In ice-9/eval.scm:

   182:19  2 (proc #(#(#<directory (scripts compile-wasm) 7fd719?> ?)))

   142:16  1 (compile-top-call #<directory (scripts compile-wasm) 7?> ?)

In unknown file:

           0 (%resolve-variable (7 . compile-file) #<directory (scri?>)

ERROR: In procedure %resolve-variable:

Unbound variable: compile-file

make: *** [Makefile:14: game.wasm] Error 1

I'm on Ubuntu 22.04LTS on wsl.

I don't know why your error is happening, but it might be WSL.

Don't use WSL... either use a VM or install linux and dual-boot.

I don't know what your setup is like but "incompatible bytecode version" errors suggest that you are using the wrong version of Guile to run 'guild compile-wasm'. If I had to guess I'd say it's using the Guile installed via apt but you need to make sure you're using the Guile you built from Git. Hope this helps!