Since the fix is as simple as moving an, "i" around, I say we just do that. 
Problem solved.

Even with a Xenomai 4/Dovetail/EVL port, you can't mix C library userspace 
headers with kernel space. The musl C library port I did with RTAI's current 
infrastructure is special because without it, you can't do floating-point in 
kernel space. It is a practice that should by all means be avoided. If there is 
no way to have raster.comp not depend on userspace headers, it should simply be 
excluded in the RTAI build.

I'm using 2.9 and master. Note that without RTAI, you will not see the problem.

Andy, you hit the nail on the head:

>I think that the problem is that folk writing HAL components for
>LinuxCNC don't realise that they are writing "Kernel sources for
>kernel 4.19" and if they compile, build and test on uspace they won't
>see any problems.

They are indeed writing kernel modules. :-)

Alec


On Wednesday, September 20, 2023 at 09:47:14 AM UTC, Rod Webster 
<r...@vehiclemods.net.au> wrote: 

I don't see why limit_axis.comp can't be revised to declare the int i; at
the top of the procedure which I was taught was best practice anyway. That
would solve the C11/C89 issue.
raster.comp needs stdlib.h for some of the conversion functions. It also
should include string.h for strchr() so it's still a bit sloppy. Surely
your compiler library includes could be modified or set in the ENV to
include these.
What version of linuxcnc are you using? I could not see the size error in
genserfuncs.c in master branch.

We really should not be taking responsibility for the RTAI kernel
compatibility. That has  to be their problem, not ours. The Linux Kernel
6.5 has been released so that seems to be 11 versions ahead of the last
RTAI compatible kernel. When do we accept that RTAI is really yesterday's
technology? Where is the port to Xenomai 4?

Rod Webster
*1300 896 832*
+61 435 765 611
Vehicle Modifications Network
www.vehiclemods.net.au


On Wed, 20 Sept 2023 at 18:27, andy pugh <bodge...@gmail.com> wrote:

> On Wed, 20 Sept 2023 at 01:17, Alec Ari <neotheu...@ymail.com> wrote:
>
> > Seriously though, the proper way to fix this is to not use c11/gnu11
> with 4.19 or 5.4 kernel sources.
>
> I think that the problem is that folk writing HAL components for
> LinuxCNC don't realise that they are writing "Kernel sources for
> kernel 4.19" and if they compile, build and test on uspace they won't
> see any problems.
>
> Is there any fundamental reason that _our_ kernel modules can't be
> compiled with gnu11 ?
>
>
> --
> atp
> "A motorcycle is a bicycle with a pandemonium attachment and is
> designed for the especial use of mechanical geniuses, daredevils and
> lunatics."
> — George Fitch, Atlanta Constitution Newspaper, 1912

>
>
> _______________________________________________
> Emc-developers mailing list
> Emc-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/emc-developers
>

_______________________________________________
Emc-developers mailing list
Emc-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-developers


_______________________________________________
Emc-developers mailing list
Emc-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to