I have a Go Script which complied to Windows and Linux where i provide it to my customers.
I started exploring Perl6 and want to write the new version with perl 6 , does anyone know if Perl 6 have any option like :
Go build , GOOS AND GOARCH where the user can set the OS and ARCH and create new executable where it will be used by the end user?
Perl 6 compiles to its own virtual machine, but from the outside it looks like an interpreted language. You don't need to set different compiling options, it will all compile to MoarVM (or Java VM) adapting to the operating system it's in.
In contrast to Go, which by default compiles to a native executable, the current Perl 6 implementation requires a virtual machine to run. This is similar to other scripting languages like Python or PHP. The virtual machine is itself an executable that is dependent on OS and ARCH.
So Perl 6 currently does not offer an option to build native executable files from scripts.
However there is a tool called Perl 6 WiX Installer Maker that can create Windows MSI installers for Perl 6 scripts. Such installers bundle everything needed to run (virtual machine, compiler and runtime) in addition to the script itself. It's still a young project, so expect some bumps on the road.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With