In order to avoid having to deal with compiling from source, I made a Debian Jessie rootfs using qemu-debootstrap, and got it up and running on my Snickerdoodle. I installed machinekit, and tried to start it, but got the same error messages, only this time without the stack smashing error. I took a look at `src/rtapi/rtapi_compat.*` like you suggested, and after splitting off `kernel_is_rtpreempt()` into a standalone test c program, I realized that my system does not have `/sys/kernel/realtime`, so `kernel_is_rtpreempt()` always returns 0. I am not sure why that file is missing, because I'm running a kernel that I patched and compiled myself.
Are there any other reliable ways to detect the rt_preempt kernel that I could try? I did not have a chance to try manually setting the flavor environment variable yet, but I will try that and see what happens. Cameron On Thursday, November 2, 2017 at 9:57:23 AM UTC-6, John Morris wrote: > > > > On 10/20/2017 12:51 PM, Cameron McQuinn wrote: > [...] > > > > I managed to compile MachineKit from source, and am trying to start it > > using the 5i25-zynq configuration (I don't actually have a bitstream to > > program the FPGA yet, just trying to get MK running). Starting from the > > command line, MachineKit errors out because the rtapi app gets > > terminated due to "stack smashing". Output to from the terminal is as > > follows: > > > [...] > > > > Interestingly, I have to "export FLAVOR=rt-preempt" in the shell before > > attempting to start machinekit, or else it tries to load > > rtapi_app_posix, which I did not compile. > [...] > > I encountered these exact same two problems a few days ago with the > amd64 Stretch packages, but can't for the life of me recall what the > problem finally was. I'm sorry to be so unhelpful here, but I'm > self-flagellating my brain over it. > > I do remember I couldn't get a handle on the 'stack smashing' problem, > so I went with the flavor detection problem instead, and it took maybe a > half hour to track down. That stuff is all in and around > `src/rtapi/rtapi_compat.*`. It might have been one of those cases where > there was an error somewhere along the way, but no error message and not > handled. Once I found it, I knew what the problem in my environment was > and easily fixed it. The 'stack smashing' thing just went away after > that, IIRC. > > Good luck, and please report back if/when you find it so it has a chance > of being fixed for the next person. > > John > -- website: http://www.machinekit.io blog: http://blog.machinekit.io github: https://github.com/machinekit --- You received this message because you are subscribed to the Google Groups "Machinekit" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. Visit this group at https://groups.google.com/group/machinekit. For more options, visit https://groups.google.com/d/optout.
