Difficulty building RTAI linuxcnc from source

More
24 Jul 2023 19:17 #276165 by southbayguy
There is no chance. No one has messed with the FPGA. I'm the only person who has even handled the board.

Please Log in or Create an account to join the conversation.

More
24 Jul 2023 20:39 #276173 by andypugh
And, as fas as I can tell no-one has done anything much with the Motenc driver either.
The last significant change was in 2012:
github.com/LinuxCNC/linuxcnc/commit/3d26...5363f1aeaaff3c4174b9

Are you running released LinuxCNC or compiling it yourself? (I have been assuming the former)
The following user(s) said Thank You: southbayguy

Please Log in or Create an account to join the conversation.

More
24 Jul 2023 21:52 #276176 by southbayguy
I am running released LinuxCNC, although I would love to be able to build it. Then I think I would have a better chance of tracking down this board issue and also be able to work on motion control, my real interest.
For fun, I edited my motenc_motion.hal file on my working machine, adding the "debug 5" line. Then I started LinuxCNC and the application failed, saying it had encountered an unknown command "debug."
My working machine is Ubuntu 4.4.3.

Please Log in or Create an account to join the conversation.

More
24 Jul 2023 23:15 #276180 by andypugh
The "debug" command was introduced in 2020 and isn't available before 2.8.0.

On older systems you could do this at the command line to set the debug level

echo 5 > /proc/rtapi/debug

If your system has a /proc/rtapi/ then that should work

Please Log in or Create an account to join the conversation.

More
25 Jul 2023 00:07 #276181 by southbayguy
At the command line on the working machine I did

echo 5 > /proc/rtapi/debug

then I started LinuxCNC and did "dmesg" at the command line. Earlier I had also done "dmesg" at the command line after starting LinuxCNC. With the higher debug level, there were many more messages from RTAI but none of them dealt with the Motenc board or its type.

When I try to build, things seem to be going okay until "make," when I get a message "Makefile.inc must specify RTPREFIX and other variables. Stop."

Please Log in or Create an account to join the conversation.

More
25 Jul 2023 00:21 #276184 by andypugh
OK, go to linuxcnc-dev/src

./autogen.sh
./configure
make
sudo make setuid

That ought to work.

Please Log in or Create an account to join the conversation.

More
25 Jul 2023 00:23 #276186 by andypugh
Actually, you probably need to install a bunch of dependencies too:

Go to linuxcnc-dev

./debian/configure
dpkg-checkbuilddeps

Will give you a list of packages to install. I typically copy it and edit it to remove the options, versions and alternatives and use it after "sudo apt-get install"
The following user(s) said Thank You: southbayguy

Please Log in or Create an account to join the conversation.

More
25 Jul 2023 02:11 #276193 by southbayguy
When I do dpkg-checkbuilddeps I get a Lllllooooooonnng list of packages. Looking at the packages, they don't seem relevant to a LinuxCNC build.
I'd like to go back to the ./configure step in the high-level build sequence. When I do ./configure things seem to go okay until the end, when configure reports it is unable to find libmodbus, so (following the suggestion in the error message), I re-run configure with "--without-libmodbus". Then configure reports the same phenomenon, missing libusb, so I re-run configure with "--without-libmodbus --without-libusb-1.0" and then configure returns:

error: /usr/src/linux-headers-4.19.195-rtai-amd64/include/linux/version.h: No such file or directory
gcc: fatal error: no input files

Indeed when I go to check what's in /usr/src/ there's nothing. It's empty.

Please Log in or Create an account to join the conversation.

More
25 Jul 2023 09:13 #276213 by andypugh
The huge list is everyting that is needed to build a LinuxCNC package including documentation). You might as well do it, even if some of them are not needed, it only takes about 5 minutes.

One of the dependencies in the list is probably linux-headers-xxx-rtai, and that will solve the version.h problem (and many others)

Please Log in or Create an account to join the conversation.

More
25 Jul 2023 13:02 #276221 by rodw
I did a video about how to build Linuxcnc and how to sort out the dependencies.

Please Log in or Create an account to join the conversation.

Time to create page: 0.268 seconds
Powered by Kunena Forum