this image contains text
freepascal installation guide by xqtr of
another droid bbs / andr01d.zapto.org:9999
::d o w n l o a d::
just go to https://freepascal.org/download.var and get the newest version of
freepascal for the platform you want. you can install it on raspberry pi or an
old netbook, except your high end pc computer.
prefer to get the one big tar file, which contains everything and its also easy
to install. get this file, extract it in a temp directory and proceed to next
step.
::i n s t a l l::
go to the temp directory, you extracted the .tar file. inside you will see a
script, named install.sh. you can execute this with root priveleges or as a
normal user. if you plan to install freepascal to /usr/bin the execute that
script with:
sudo ./install.sh
my way is to install freepascal to a different directory where i put all my
programming files, compilers etc. for example suppose we are installing fp to
a directory names as fpc in your home directory. so excute the installation
script as a normal user with:
./install.sh
just follow the instructions and when you asked about the installation folder,
enter the one you prefer. for example /home/user/fpc. the script will also ask
about installing some source code, examples and documentation. if you have
enough free space, install them all. they are useful and may be you will need
them in the future.
after the installation is finished we have to configure the system to find any
libraries and also execute the compiler from where ever directory we are in.
::c o n f i g u r a t i o n::
because we executed the installation script with normal priveleges, it hasnt
saved the config file to the default location which is /etc/fpc.cfg. instead
you will find it inside the ./bin folder, inside the folder where you installed
freepascal. copy that file to your home directory and name it like .fpc.cfg.
if you installed freepascal at /home/user/fpc then give the following command:
cp /fpc/fpc.cfg /.fpc.cfg
also we have to tell to the system where to find the bin utils and compiler of
freepascal. so we have to add to the path enviroment variable the directory in
which we installed freepascal. with an editor like nano, vi, gedit, geany, edit
the file .bashrc which is inside your home folder like this:
nano .bashrc
to the bottom of the file add the following:
PATHPATH:/fpc/bin
export PATH
this will tell to the system to also look inside the /fpc/bin directory for
executables, which fpc compiler is. to enable the changes give the following
command:
source /.bashrc
you are ready to use freepascal. to test it out, just execute fpc in a terminal
and also execute the program fp which is a very cool ide for freepascal.
::e x t r a s::
even though you are ready to use freepascal and make some cool programs, in the
future you may need some extra libraries, like sqlite. freepascal has units to
support sqlite, but it needs also a library to be installed, to the system. to
do so, install the libsqlite3-dev package with:
sudo apt-get install libsqlite3-dev
for playing mod, xm, it etc track files you will need the bass library, which
is awesome. you can find it at: http://www.un4seen.com/
for cool graphics, with lighting effects, sprites and more install the zengl
engine, from http://zengl.org/.
more about freepascal and development for ascii/ansi graphics to come in the
future
another droid bbs / andr01d.zapto.org:9999
::d o w n l o a d::
just go to https://freepascal.org/download.var and get the newest version of
freepascal for the platform you want. you can install it on raspberry pi or an
old netbook, except your high end pc computer.
prefer to get the one big tar file, which contains everything and its also easy
to install. get this file, extract it in a temp directory and proceed to next
step.
::i n s t a l l::
go to the temp directory, you extracted the .tar file. inside you will see a
script, named install.sh. you can execute this with root priveleges or as a
normal user. if you plan to install freepascal to /usr/bin the execute that
script with:
sudo ./install.sh
my way is to install freepascal to a different directory where i put all my
programming files, compilers etc. for example suppose we are installing fp to
a directory names as fpc in your home directory. so excute the installation
script as a normal user with:
./install.sh
just follow the instructions and when you asked about the installation folder,
enter the one you prefer. for example /home/user/fpc. the script will also ask
about installing some source code, examples and documentation. if you have
enough free space, install them all. they are useful and may be you will need
them in the future.
after the installation is finished we have to configure the system to find any
libraries and also execute the compiler from where ever directory we are in.
::c o n f i g u r a t i o n::
because we executed the installation script with normal priveleges, it hasnt
saved the config file to the default location which is /etc/fpc.cfg. instead
you will find it inside the ./bin folder, inside the folder where you installed
freepascal. copy that file to your home directory and name it like .fpc.cfg.
if you installed freepascal at /home/user/fpc then give the following command:
cp /fpc/fpc.cfg /.fpc.cfg
also we have to tell to the system where to find the bin utils and compiler of
freepascal. so we have to add to the path enviroment variable the directory in
which we installed freepascal. with an editor like nano, vi, gedit, geany, edit
the file .bashrc which is inside your home folder like this:
nano .bashrc
to the bottom of the file add the following:
PATHPATH:/fpc/bin
export PATH
this will tell to the system to also look inside the /fpc/bin directory for
executables, which fpc compiler is. to enable the changes give the following
command:
source /.bashrc
you are ready to use freepascal. to test it out, just execute fpc in a terminal
and also execute the program fp which is a very cool ide for freepascal.
::e x t r a s::
even though you are ready to use freepascal and make some cool programs, in the
future you may need some extra libraries, like sqlite. freepascal has units to
support sqlite, but it needs also a library to be installed, to the system. to
do so, install the libsqlite3-dev package with:
sudo apt-get install libsqlite3-dev
for playing mod, xm, it etc track files you will need the bass library, which
is awesome. you can find it at: http://www.un4seen.com/
for cool graphics, with lighting effects, sprites and more install the zengl
engine, from http://zengl.org/.
more about freepascal and development for ascii/ansi graphics to come in the
future
log in to add a comment.