* Mini build while experimenting with C programming?
@ 2024-12-22 1:25 jon
2024-12-22 10:17 ` Matthias Fischer
2024-12-23 11:23 ` Michael Tremer
0 siblings, 2 replies; 3+ messages in thread
From: jon @ 2024-12-22 1:25 UTC (permalink / raw)
To: development
[-- Attachment #1: Type: text/plain, Size: 655 bytes --]
All,
Is there a way to compile a C program and not run the entire ipfire `make.sh build`. And include the various ipfire `#include` items?
I am attempting to compile an `rpzctrl.c` file for the `rpz.cgi` webgui. I am in the early stages of C programming and I am making lots of errors. And so each iteration of C code takes 2-3 hours for a `make.sh build`.
I'd like to do something like:
```
gcc -I ./build_x86_64/usr/include rpzctrl2.c -o rpzctrl
```
I don't know which `include` files directory to reference so I just picked one. But running gcc throws lots of errors.
Can you get me started?
Merry Christmas all,
Jon
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Mini build while experimenting with C programming?
2024-12-22 1:25 Mini build while experimenting with C programming? jon
@ 2024-12-22 10:17 ` Matthias Fischer
2024-12-23 11:23 ` Michael Tremer
1 sibling, 0 replies; 3+ messages in thread
From: Matthias Fischer @ 2024-12-22 10:17 UTC (permalink / raw)
To: development
[-- Attachment #1: Type: text/plain, Size: 1166 bytes --]
Hi Jon,
as far as I remember:
The compilation of these C-files is controlled by 'lfs/misc-progs'
(make.sh / Core 189 / line 1720) and logged in a file named something
like 'log_x86_64/misc-progs'.
To put it in a nutshell: it could be sufficient if you just delete this
specific log file and start 'make.sh build' again. The lack of this log
file will trigger a new compilation process of 'misc-progs'.
HTH,
Matthias
On 22.12.2024 02:25, jon wrote:
> All,
>
> Is there a way to compile a C program and not run the entire ipfire `make.sh build`. And include the various ipfire `#include` items?
>
> I am attempting to compile an `rpzctrl.c` file for the `rpz.cgi` webgui. I am in the early stages of C programming and I am making lots of errors. And so each iteration of C code takes 2-3 hours for a `make.sh build`.
>
> I'd like to do something like:
>
> ```
> gcc -I ./build_x86_64/usr/include rpzctrl2.c -o rpzctrl
> ```
>
> I don't know which `include` files directory to reference so I just picked one. But running gcc throws lots of errors.
>
> Can you get me started?
>
> Merry Christmas all,
> Jon
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Mini build while experimenting with C programming?
2024-12-22 1:25 Mini build while experimenting with C programming? jon
2024-12-22 10:17 ` Matthias Fischer
@ 2024-12-23 11:23 ` Michael Tremer
1 sibling, 0 replies; 3+ messages in thread
From: Michael Tremer @ 2024-12-23 11:23 UTC (permalink / raw)
To: development
[-- Attachment #1: Type: text/plain, Size: 1185 bytes --]
Hello Jon,
The easiest way to do this is to run the entire build from next or master once until it is completed.
You can then run “./make.sh shell” which will drop you into a shell in the build environment. In there, you can run the gcc commands with the IPFire compiler, headers and use the entire rest of the user land.
You should not need any special search paths for any include files.
-Michael
> On 22 Dec 2024, at 02:25, jon <jon.murphy(a)ipfire.org> wrote:
>
> All,
>
> Is there a way to compile a C program and not run the entire ipfire `make.sh build`. And include the various ipfire `#include` items?
>
> I am attempting to compile an `rpzctrl.c` file for the `rpz.cgi` webgui. I am in the early stages of C programming and I am making lots of errors. And so each iteration of C code takes 2-3 hours for a `make.sh build`.
>
> I'd like to do something like:
>
> ```
> gcc -I ./build_x86_64/usr/include rpzctrl2.c -o rpzctrl
> ```
>
> I don't know which `include` files directory to reference so I just picked one. But running gcc throws lots of errors.
>
> Can you get me started?
>
> Merry Christmas all,
> Jon
>
>
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2024-12-23 11:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-12-22 1:25 Mini build while experimenting with C programming? jon
2024-12-22 10:17 ` Matthias Fischer
2024-12-23 11:23 ` Michael Tremer
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox