p4nd4, not in B&W.

zoe and lustelumenya

Download and Install (1 of 2)

DOWNLOAD AND INSTALL ( 1 of 2 )
0. Prerequisites

Satisfy yourself that:
        gcc
        cmake
are installed.

(most often, gcc will already be installed along with OS.)
(cmake is a very useful skill to obtain....even if you do not go very far with zoe.)

AND THEN:
sudo apt-get install build-essential
(This is necessary.  It will be repeated again!)

REPEAT:

#POSSIBLY
sudo apt autoremove

#MAYBE
sudo snap install cmake --classic

#ALWAYS
sudo apt-get install build-essential


Satisfy Yourself that your command prompt is running and is located in the directory where you unpacked the source code on the interpreter. 

1. Compile

1.1  GRAB and UNPACK THE zoe INTERPRETER SOURCE CODE:

Download Interpreter

You will pull down a .gz file; please unpack this is a location of your choice. Follow your usual safety procedures, and/or those of your school, company etc. Run security on it; satisfy yourself that it is safe to have on your PC. Let's take this chance to chant the mantra: "SATISFY YOURSELF THAT YOU ARE SAFE AND SECURE" Shortly, you will be running a compiler 1.2 IMMEDIATELY INSTALL: (this is old, and may not be needed.....depends on your OS/Ver) NOTE for using gcc / cmake on Debian. #gcc and cmake is not enough to install. Do this too: sudo apt-get update && sudo apt-get install build-essential #install ncurses library: apt-get install ncurses-dev #readline library does not seem to be installed on Debian. #try this: apt-get install libreadline6-dev #or maybe this: apt-get install libreadline-gplv2-dev (IF YOU SEE THE FOLLOWING: see the following: ........./main.c:112:10: fatal error: readline/readline.h: No such file or directory 112 | #include | ^~~~~~~~~~~~~~~~~~~~~ ) TAKE THIS ACTION: sudo apt-get install libreadline-dev AND THEN we can install application! STEP 0. Get In The Correct Place Wherever you have unpacked to, move there. You will see a directory inside there named: 0.5.7 move (cd) into this, and list (ls .) the contents. Can you see [ 011.zoe ]? If so, you are in the correct place....well done. (what am I looking at?? You can see source files for the compiler; and some helpful notes. You can also see a source code file in the zoe programming language. Before this can be run, we have to compile the interpreter. ) STEP 1. cmake . STEP 2. make AT THIS STAGE, you should be able to see the newly-compiled-and-assembled programme. It is called 'zoe' STEP 3. { 2 Possibilities!! } { OPTIONAL !! } make install ^^^^^^^^^^^MAYBE you have to run this as sudo: sudo make install * Note that this step is to enable access to the zoe interpreter from 'all over' your OS. It could be that you do not wish / need this; in which case, skip this step -- but bear in mind that zoe will run only from this directory. Choice is yours. 1.3 Delete an Unwanted File -- May not be needed. But be aware of how to act against the message if you see it in the future....... IF you see the following error: "CMake Error: The current CMakeCache.txt directory /home/you/(etc etc) join Strings together/CMakeCache.txt is different than the directory /home/etc etc where CMakeCache.txt was created. This may result in binaries being created in the wrong place. If you are not sure, reedit the CMakeCache.txt" (this causes problems during Compiletion) DO NOT WORRY! DO NOT PANIC! Delete this file: CMakeCache.txt by doing: rm CMakeCache.txt You can delete CMakeCache.txt as often as you wish; but please think twice about deleting anything else (your property, your choice ) 1.4 Segmentation fault (core dumped) Are you trying to access a text file from another directory??? If you are executing ./zoe, and your program (maybe ./000-New/WW3-Web.zoe) is in a 'lower' directory, MAKE SURE that there is a copy of the file in ./zoe. This problem will go away when your program is installed 2.1 Running Move Command Line to THIS directory, and execute: ./zoe ./011.zoe to 'prove' that you are in the right place. WHAT ARE THE DOTS AND DASHES? the ./ are to let the operating system know that that you are executing a compiled (machine code) programmer (zoe) and asking it to execute an interpreted, not compiled, programme (001.zoe), both of which are in *this* directory. WHAT SHOULD HAPPEN UPON EXECUTION? You should see: "Oh! Doctor!!" On your command line..... If you see this, well, congratulations. Let's revisit what you have done: 1. Obtained the source code (in C) for the zoe interpreter 2. Obtained the Compiler etc. (gcc and cmake) 3. Compiled the source code into an application 4. Executed the application Congratulations !
;