hints and a noob question answered please. about linking /embedding a file.

Just starting out? Need help? Post your questions and find answers here.
noxidderf
User
User
Posts: 18
Joined: Thu Oct 03, 2024 5:31 pm

hints and a noob question answered please. about linking /embedding a file.

Post by noxidderf »

I want to add or embed or link a file with a purebasic program.
I do not know what I am doing. just looking for pointer to what i need to know.
I dont know enough to ask the right questions.
I have a javascript engine ( quickJS ) that I want to work with.
I have the project compiled from github.
I have a stand alone program. i have the headers files. I also have a libquickjs.a file.
I think that might be what I want to work with but I dont know.
some places tell me this is an archive.
it might also be a object file that can be used with the header.
like I said I just would like a couple of hints and maybe where to look.


I usually just make some simple script or command line thinks to make things easy on my pc.
Fred.



Purbasic 6.20
OS: Pop!_OS 22.04 LTS x86_64 (ubuntu)
Terminal: gnome-terminal
CPU: AMD Ryzen 7 8845HS w/ Radeon 780M Graphics (16) @ 5.137GHz
GPU: AMD ATI 66:00.0 Device 1900
Memory: 18174MiB / 61082M
boddhi
Enthusiast
Enthusiast
Posts: 524
Joined: Mon Nov 15, 2010 9:53 pm

Re: hints and a noob question answered please. about linking /embedding a file.

Post by boddhi »

noxidderf wrote: I want to add or embed or link a file with a purebasic program.
It's a topic that's been discussed many times, and you can find it with the search module.

You can use IncludeBinary.
An example among many published : https://www.purebasic.fr/english/viewto ... 55#p593755
If my English syntax and lexicon are incorrect, please bear with Google translate and DeepL. They rarely agree with each other!
Except on this sentence...
User avatar
STARGÅTE
Addict
Addict
Posts: 2226
Joined: Thu Jan 10, 2008 1:30 pm
Location: Germany, Glienicke
Contact:

Re: hints and a noob question answered please. about linking /embedding a file.

Post by STARGÅTE »

A couple of hints:

registry
file extension
MIME type
ProgramParameter()
PB 6.01 ― Win 10, 21H2 ― Ryzen 9 3900X, 32 GB ― NVIDIA GeForce RTX 3080 ― Vivaldi 6.0 ― www.unionbytes.de
Lizard - Script language for symbolic calculations and moreTypeface - Sprite-based font include/module
AZJIO
Addict
Addict
Posts: 2141
Joined: Sun May 14, 2017 1:48 am

Re: hints and a noob question answered please. about linking /embedding a file.

Post by AZJIO »

noxidderf wrote: Wed Feb 19, 2025 6:43 am I want to add or embed or link a file with a purebasic program.
Use purebasic_gtk2
https://www.purebasic.fr/english/viewtopic.php?t=83762
noxidderf
User
User
Posts: 18
Joined: Thu Oct 03, 2024 5:31 pm

Re: hints and a noob question answered please. about linking /embedding a file.

Post by noxidderf »

boddhi wrote: Wed Feb 19, 2025 7:00 am
noxidderf wrote: I want to add or embed or link a file with a purebasic program.
It's a topic that's been discussed many times, and you can find it with the search module.

You can use IncludeBinary.
An example among many published : https://www.purebasic.fr/english/viewto ... 55#p593755


not whatI was trying to say.
the post linked has a file contained inside the executable.
I asked the question in a wrong way. I was not sure how to ask it.
This is an example of what I was talking about
https://www.purebasic.fr/english/viewtopic.php?t=67365
where lua and purebasic has access back and forth.
I was also trying to figure out if while compiling quickJS (the original) was also being compiled as a library to be call externally.
noxidderf
User
User
Posts: 18
Joined: Thu Oct 03, 2024 5:31 pm

Re: hints and a noob question answered please. about linking /embedding a file.

Post by noxidderf »

after much research mostly because I dont know enough to ask the right questions.
I assumes some here might have worked with such a thing. after all someone did the thing with lua.
I am putting here what I found. it is a longish post from 'grok' about my question. posting the link not sure if posting all the text is ok or not so link:

https://x.com/i/grok/share/1fDpEf9pYBdTjxemLwGz7iml0
answers the question about linking the static compiled library (and that it is a library)

Fred.
Post Reply