How to implement new Haxe target?

When running bash.exe on its own (not inside of cmd.exe), the commands opam, make etc are not found at all

I wouldn’t use cmd.exe at all, but maybe that’s just me…

Maybe you’re supposed to do the whole installation from bash.exe? (not inside of cmd.exe)

Do you have a working setup on Windows capable of compiling haxe?

Nope sorry, only linux.

Heeb@HeebLenovo /cygdrive/c/HaxeToolkit/dev/haxe
$ make -f Makefile.win
/usr/bin/make -C libs/extlib-leftovers native && /usr/bin/make -C libs/extc native && /usr/bin/make -C libs/neko native && /usr/bin/make -C libs/javalib native && /usr/bin/make -C libs/swflib native && /usr/bin/make -C libs/ttflib native && /usr/bin/make -C libs/ilib native && /usr/bin/make -C libs/objsize native && /usr/bin/make -C libs/pcre native && /usr/bin/make -C libs/ziplib native && true
make[1]: Entering directory '/cygdrive/c/HaxeToolkit/dev/haxe/libs/extlib-leftovers'
ocamlopt -safe-string -g -a -o extlib-leftovers.cmxa multiArray.mli rbuffer.mli uChar.mli uTF8.mli multiArray.ml rbuffer.ml uChar.ml uTF8.ml
e[1mFile "e[1mcommand line", line 1e[0me[0m:
e[1;31mErrore[0m: Unbound module Pervasives
make[1]: *** [Makefile:25: extlib-leftovers.cmxa] Error 2
make[1]: Leaving directory '/cygdrive/c/HaxeToolkit/dev/haxe/libs/extlib-leftovers'
make: *** [Makefile:114: libs] Error 2

Is it possible to cross-compile haxe, i.e. create a haxe.exe that I can then run on Windows?

@Gama11 said somewhere above that he doesn’t think it’s a thing.

I’ll try some things though, I need to get a working custom haxe build for windows. I’ll let you know if I find something.

1 Like

Since I only need one build, I can use appveyor artifacts from a PR to haxe github repository.

I don’t think it’d be useful for your use case though, as you’d have to wait somewhere between 30min and 4 hours for each build =/

Thanks.
Just out of curiosity: Do you have insight into how the actual downloadable haxe.exe is built?
It must be built somehow, either on some Windows server or on a Linux server…

Appveyor builds it from this script: https://github.com/HaxeFoundation/haxe/blob/development/appveyor.yml