Quick install Linux

   

This is a sup­ple­ment to the page Bol Processor ‘BP3’ and its PHP inter­face.

This instal­la­tion is checked with Ubuntu + Linux Lite 7.0 run­ning on an HP Intel Core i5-6200U (64-bit, 8 Gb RAM).

Install XAMPP

The instal­la­tion of BP3 should take place after the instal­la­tion of the local Apache serv­er XAMPP. Follow instruc­tions here: https://www.apachefriends.org/

XAMPP cre­ates a /opt/lampp/htdocs/ direc­to­ry that will con­tain "bolprocessor". The "bolprocessor" fold­er will con­tain (lan­guage C) source files for the "bp3" con­sole, the "MakeFile" to com­pile them, and all the data files. It will also con­tain a "php" fold­er filled with PHP pages and some relat­ed files for run­ning the interface.

If you wish to open XAMPP auto­mat­i­cal­ly at start­up, read this page.
(This can be done later.)

Download Bol Processor files

You need these files:

bolprocessor-graphics-for-BP3.zip con­tains source files for cre­at­ing the BP3 con­sole;
php-frontend-master.zip con­tains the PHP inter­face;
bp3-ctests-main.zip con­tains a set of exam­ples called "ctests".

These zip files are updat­ed reg­u­lar­ly. Major updates are announced on the BP devel­op­ers list and uploaded to their GIT repos­i­to­ries. Make sure that they can be found in your Downloads fold­er: /home/linuxlite/Downloads

Install the Bol Processor

Safely do the instal­la­tion using the shell scripts "linux-scripts" down­loaded here.
Current ver­sion: 4 February 2025, size 14124 bytes.
Unpack and copy these scripts to the /home folder:

cd /home/linuxlite/Downloads/
unzip linux-scripts.zip -x "__MACOSX/*"
sudo chmod -R 775 linux-scripts
cd linux-scripts
sudo cp -a . /home/
cd /home/
sudo chmod +x *.sh

Scripts "modify_xampp.sh", "prepare.sh", "unpack_bp3.sh", "install_bp3.sh" and "get_ready_bp3.sh" have been copied to the /home fold­er.

Four more scripts: "update_console.sh", "update_interface.sh", "update_data.sh" and "restart_xampp.sh", have been copied to the /home fold­er. They will be used later.

The instal­la­tion pro­ce­dure is sim­i­lar to that for MacOS and Windows, but includes a few actions spe­cif­ic to Linux.

Run the scripts in the fol­low­ing order.
👉   You will be asked for your pass­word the first time, as they need to be run in "admin" mode (the "sudo" com­mand).

  1. sudo /home/modify_xampp.sh will adjust XAMPP settings.
  2. sudo /home/prepare.sh will install required resources on your machine, and cre­ate two vir­tu­al MIDI ports if they are not yet existing.
  3. sudo /home/unpack_bp3.sh will unpack the zip files.
  4. sudo /home/install_bp3.sh will cre­ate the /opt/lampp/htdocs/bolprocessor/ direc­to­ry and fill it with the con­tents of BP3 pack­ages. Files/folders already exist­ing will sim­ply be updated.
  5. sudo /home/get_ready_bp3.sh will con­fig­ure the vir­tu­al MIDI ports and update the sudo­ers entry.

In the "bolprocessor" fold­er, the own­er is "daemon" (the same one used by XAMPP), which is assigned to the groups "audio" and "linuxlite", and the per­mis­sions are set to "775".
👉 The con­tent of "bolprocessor" is strict­ly pri­vate. No risk set­ting up permissions!

Avoid run­ning the same script more than once, although this should not cre­ate dupli­cates or unwant­ed effects.

Once the Bol Processor BP3 is installed and run­ning, you should delete the "zip" files in the Downloads fold­er. This will allow down­load­ing new versions.

Compile the 'bp3' console

Start the XAMPP Apache serv­er. You can send the ter­mi­nal command:

sudo /home/restart_xampp.sh

Point your brows­er at localhost/bolprocessor/php/. This will dis­play the home page of the Bol Processor.

If you see this frame in the image at the top right of the page, your life will be easy! All you have to do is click on the link to com­pile the con­sole, which will take less than a minute.

f you don't see the link to com­pile, and instead a men­tion that 'gcc' is not respon­sive, you are in great trou­ble! This sug­gests a bug in the inter­face (con­tact us) or in your installation.

Install Csound

Csound is not required to run the Bol Processor, as you can work with MIDI files and real-time MIDI. However, it will give you access to a dif­fer­ent approach to sound syn­the­sis, and it will han­dle micro­tonal­i­ty in its own way.

If you wish to install Csound, sim­ply type the fol­low­ing commands:

sudo apt update
sudo apt install csound

Then ver­i­fy the instal­la­tion and check the path to the console:

csound --ver­sion
which csound

By default, the Bol Processor sets the path to "usr/bin", which seems to be stan­dard on Linux. It is giv­en by the "which csound" com­mand.

A frame ask­ing for a cor­rec­tion
of the path to Csound.
The path "/usr/local/bin" is incor­rect in Linux.

The BP3 inter­face will be able to fig­ure out the loca­tion of "csound" and fix its path accord­ing­ly. If it does not respond, you will be asked to change the path and per­haps the name of the Csound con­sole (see image).

Contact us if this happens!

👉 Currently, the Csound orches­tra file "0-default.orc" does not work on Linux. We're try­ing to fix this… In the set­tings of your projects, enter "BP2test.orc" as replace­ment, or select oth­er files such as "new-vina.orc".

😀  Enjoy Bol Processor BP3 on Linux!

Restarting XAMPP after a crash

If you blow up the mem­o­ry, for exam­ple with a quan­ti­za­tion that is too low for the size of a piece played in real­time MIDI, the XAMPP serv­er may freeze: the brows­er will refuse to dis­play pages.

To restart XAMPP, go to the ter­mi­nal and run the fol­low­ing script:

sudo /home/restart_xampp.sh

Updating to new versions

👉  If you update the "bp3" con­sole, you should also update the PHP inter­face, as the two are linked.

  • (1) Update the "bp3" con­sole:
    Delete the graphics-for-BP3.zip file if it exists in your Downloads fold­er.
    Download https://github.com/bolprocessor/bolprocessor/archive/graphics-for-BP3.zip
    Run the (super­fast!) script: sudo /home/update_console.sh
    This script deletes the 'bp3' con­sole to force a com­pi­la­tion of the new version.
  • (2) Update the PHP inter­face:
    Delete the php-frontend-master.zip file if it exists in your Downloads fold­er.
    Download https://github.com/bolprocessor/php-frontend/archive/master.zip
    Run the (super­fast!) script: sudo /home/update_interface.sh
    Note that this script will pre­serve the "_settings.php" file (if it exists), which con­tains your project settings.
  • (3) Update the set of exam­ples: this will only update the con­tents of the "ctests" fold­er. If you have cre­at­ed fold­ers and files for your per­son­al data, these will not be affect­ed. However, if you have mod­i­fied a sam­ple file with­out chang­ing its name, it will be revert­ed to its dis­tri­b­u­tion ver­sion.
    Delete the bp3-ctests-main.zip file if it exists in your Downloads fold­er.
    Download https://github.com/bolprocessor/bp3-ctests/archive/main.zip
    Run the (super­fast!) script: sudo /home/update_data.sh

👉 Please send your sug­ges­tions or mod­i­fied files to our con­tact.

Relocating "bolprocessor"

The Bol Processor can be installed out­side the "htdocs" fold­er cre­at­ed by XAMPP (on your boot dri­ve). You might want it near relat­ed projects, or use extra space from an exter­nal hard dri­ve. There may also be sit­u­a­tions where cre­at­ing files on the boot dri­ve is restricted.

Fortunately, the process of relo­cat­ing is very straight­for­ward. Not all cas­es have been test­ed, but instal­la­tion and update scripts are designed to han­dle redirections.

You should have already cre­at­ed a "bolprocessor" fold­er by run­ning the installer. Now, drag it to the desired loca­tion and delete it from the "htdocs" fold­er.

Then, open a ter­mi­nal and point it to the "htdocs" direc­to­ry. You can type the instruc­tion "ls -al" to see the con­tents of "htdocs", which is nor­mal­ly empty.

Let's say you've cre­at­ed an emp­ty fold­er "bolprocessor" inside a fold­er called "MUSIC" on an exter­nal dri­ve called "EXT". You first need to find the path to the exter­nal dri­ve. Plug in the dri­ve, then type "lsblk". Look for the device name (e.g., "/dev/sdb1") and its mount point, e.g. "/media/username/EXT", where "username" is your own user name.

The com­mand to cre­ate the sym­bol­ic link would then be:

ln -s /media/username/EXT/MUSIC/bolprocessor bolprocessor

Make sure that the sym­bol­ic link you cre­at­ed points to the cor­rect loca­tion: you will now see a "bolprocessor" icon in the "htdocs" fold­er. Double-click it, it should open the des­ti­na­tion folder.

You can now safe­ly run the update scripts and pro­ceed to com­pile the 'bp' con­sole. Don't try to run the instal­la­tion scripts!

Make sure you use the lat­est ver­sion of the scripts, as they are designed to work with sym­bol­ic links.

👉 Never change the names of the "bolprocessor" fold­er and sym­bol­ic link, oth­er­wise the instal­la­tion will fail.

The first time you run the Bol Processor, XAMPP may ask your per­mis­sion to dis­play files out­side its "htdocs" fold­er. Please con­tact us if you're expe­ri­enc­ing issues with this relocation!

You can also use sym­bol­ic links to relo­cate fold­ers out­side the "bolprocessor" fold­er, as explained here.

Uninstall the Bol Processor

Uninstalling the Bol Processor and all the data down­loaded or cre­at­ed for its use, is very sim­ple: delete the "htdocs/bolprocessor" fold­er, or the relo­cat­ed "bolprocessor" fold­er and the sym­bol­ic link point­ing to it.

Bernard Bel
Created: August 2024

Leave a Reply

Your email address will not be published. Required fields are marked *