Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Linux specific forum
User avatar
TI-994A
Addict
Addict
Posts: 2741
Joined: Sat Feb 19, 2011 3:47 am
Location: Singapore
Contact:

Re: Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Post by TI-994A »

Some personal notes when installing PureBasic on Ubuntu 18.04, 20.04 and 24.04:

1. When performing the updates as detailed in the INSTALL file, errors like "no installation candidate" might occur. Always best to run a general update first (apt update) before performing the other updates.

2. In the application desktop file (PureBasic.desktop):
a. Append the %F directive to the Exec key value to include the PureBasic application in the "Open with" application list.

b. Include the MimeType key value as indicated in the mime XML file (purebasic.xml), to properly configure file associations so that PureBasic will be launched when .pb/.pbi/.pbf files are selected in the file manager.

c. Include the StartupWMClass key value so that the application icon will be displayed in the task bar when launched at the command line or by clicking an associated file.. This value can be obtained by running xprop WM_CLASS in a terminal window, then clicking on the PureBasic IDE window.

Application Desktop file (saved to /home/[username]/.local/share/applications/PureBasic.desktop)

Code: Select all

[Desktop Entry]
Type=Application
Icon=/home/[username]/Apps/purebasic/logo.png
Name=PureBasic v6.12 LTS
Comment=Developer Utility
Categories=Development
MimeType=application/purebasic
Exec=/home/[username]/Apps/purebasic/compilers/purebasic %F
Path=/home/[username]/Apps/purebasic/compilers
StartupWMClass=purebasic
StartupNotify=true
Terminal=false

Mime XML file (saved to /home/[username]/.local/share/mime/packages/purebasic.xml)

Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<mime-info xmlns='http://www.freedesktop.org/standards/shared-mime-info'>
   <mime-type type="application/purebasic">
      <comment>PureBasic source code</comment>
      <glob pattern="*.pb"/>
      <glob pattern="*.pbi"/>
      <glob pattern="*.pbf"/>
   </mime-type>
</mime-info>

After making these changes, update the desktop and mime databases in terminal:

Code: Select all

update-desktop-database ~/.local/share/applications
update-mime-database    ~/.local/share/mime


Nevertheless, it's still unable to open a PureBasic file by double-clicking it if the IDE is already running. :lol:
Texas Instruments TI-99/4A Home Computer: the first home computer with a 16bit processor, crammed into an 8bit architecture. Great hardware - Poor design - Wonderful BASIC engine. And it could talk too! Please visit my YouTube Channel :D
User avatar
Blue
Addict
Addict
Posts: 968
Joined: Fri Oct 06, 2006 4:41 am
Location: Canada

Re: Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Post by Blue »

Holy cow !
is everything this involved and complicated on Linux ?
I just installed Mint on a computer no longer able to run Windows. Win-11 simply won't install on it, no matter which trick i try.
So I decided it was time to dip a toe or two in Linux waters... and i definitely find the water cold !

Anyway, I got Mint running and I like what i see so far, even though the whole thing still sounds greek to me. Now I want to install and run PB on my newly Minted system, but it's scary...
PB Forums : Proof positive that 2 heads (or more...) are better than one :idea:
User avatar
greyhoundcode
Enthusiast
Enthusiast
Posts: 113
Joined: Sun Dec 30, 2007 7:24 pm

Re: Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Post by greyhoundcode »

> is everything this involved and complicated on Linux ?

Not really, no. Sometimes you might hit some rough edges, though, and this is perhaps one of them. Persevere, though, it really is worth it.
User avatar
Blue
Addict
Addict
Posts: 968
Joined: Fri Oct 06, 2006 4:41 am
Location: Canada

Re: Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Post by Blue »

Well, once I finally understood the words in TI-994A’s instructions, it went well and I got PB installed in the folder of my choice in Mint 22. Everything works as expected : the icons, the opening of source files by clicking on them, the Help file, everything. However, I think that the instructions provided by TI-994A would benefit from some refinement and clarifications. :?

For someone who has worked almost exclusively with Windows since the mid 90’s, getting into Linux was quite intimidating and disorienting. I don’t think I would have persisted without the help and steady encouragement of my good friend Moulder. The Linux aficionado, expert and gifted humorist that he is provided a lot of moral support and fine tuned help. Without him, I probably would still be crying under my desk… :)
PB Forums : Proof positive that 2 heads (or more...) are better than one :idea:
User avatar
moulder61
Enthusiast
Enthusiast
Posts: 205
Joined: Sun Sep 19, 2021 6:16 pm
Location: U.K.

Re: Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Post by moulder61 »

@Blue

Glad I could help. :wink:

Not sure about "expert"? :oops:

You know where I am if you need me. 8)

Moulder.
"If it ain't broke, fix it until it is!

This message is brought to you thanks to SenselessComments.com

My PB stuff for Linux: "https://u.pcloud.link/publink/show?code ... z3MR0T3jyV
User avatar
marcoagpinto
Addict
Addict
Posts: 1076
Joined: Sun Mar 10, 2013 3:01 pm
Location: Portugal
Contact:

Re: Simple install of PureBasic (Ubuntu, Mint, Raspberry)

Post by marcoagpinto »

What about an installer?

I am thinking about a .deb file.

I have installed software clicking on such files.
Post Reply