1

I downloaded Rebol/View (vesion 2.7.8) Linux x86 libc6 2.3 version from http://www.rebol.com/downloads.html and it is working all right as an interpreter on Linux (Debian Stable 9). Is it possible to compile the code to executables? I tried checking the options, and compile to executable option does not seem to be there:

$ rebol -v --help
The command line usage is:

    REBOL <options> <script> <arguments>

All fields are optional. Supported options are:

    --cgi (-c)       Check for CGI input
    --do expr        Evaluate expression
    --link url       Connect to Link
    --help (-?)      Display this usage information
    --nowindow (-w)  Do not open a window
    --noinstall (-i) Do not install (Link, View)
    --quiet (-q)     Don't print banners
    --reinstall (+i) Force an install (Link, View)
    --script file    Explicitly specify script
    --secure level   Set security: allow ask throw quit
    --trace (-t)     Enable trace mode
    --uninstall (-u) Uninstall REBOL (Link, View)
    --version tuple  Minimum version of script, when URL (View)
    --noviewtop (-v) Do not start viewtop (view desktop)

Special command line options:

    +q               Force not quiet (Link, View)
    -s               No security
    +s               Full security
    -- args          Provide args without a script

Examples:

    REBOL script.r
    REBOL -s script.r
    REBOL script.r 10:30 test@domain.dom
    REBOL --do "verbose: true" script.r
    REBOL -cswq
    REBOL --cgi --secure throw --script cgi.r "debug: true"
    REBOL --version 1.2.3 http://www.rebol.net/test.r ; view only

Can I compile Rebol code to executable code on Linux/Windows? Thanks for your help.

rnso
  • 23,686
  • 25
  • 112
  • 234

2 Answers2

4

In theory there should be a commercial SDK for Rebol available that bundles the interpreter with your script to one file, no native compiler.

Red uses Rebol to compile Red and Red/System for all supported platforms (Windows, Linux, Mac, Android etc), even crosscompiling. The compiler is included in the stable builds and automated builds. How to compile see the README and also RedEd

sqlab
  • 6,412
  • 1
  • 14
  • 29
3

Rebol/View can be packed with the interpreter using a product called Encap which was available from Rebol Technologies. I don't know if they still sell this, or even if the company still exists.

Red, a Rebol 2 clone with an enhanced GUI, can compile to binary as far as I know.

Ren-c, a Rebol3 derivative, can be compiled from C source so you can compile in any code you want. However, there is no GUI support at present though one branch in planning to add this.

Graham Chiu
  • 4,856
  • 1
  • 23
  • 41
  • Apparently, Red creating binary executable is currently for Windows only, not for Linux. Moreover, Red seems to be still in alpha so one is worried if it may cause crash and damage data. – rnso Sep 14 '17 at 07:32
  • What is the best way to distribute my program to be run on Windows platform? – rnso Sep 14 '17 at 07:41
  • Encap if using Rebol2/View. That's the one that offers source code protection. I don't know much about red-lang. Maybe DocKimbel will appear to answer. – Graham Chiu Sep 14 '17 at 08:57
  • @DocKimbel instead of DocKimble for SO user's attention. – rnso Sep 14 '17 at 13:03