John, >> Honestly, I think the simplest approach is to build the kernel, rtai, and EMC all on the system on which you are going to run it. That reduces the number of variables.
Did you have some specific reason for doing the build on Debian Lenny, or is that just because the wiki page used Lenny? << Ok, that is where I started, but got hung up on the general instructions for building an RTAI kernel. I went to Debian Lenny for the very pragmatic reason that those instructions work as written. I had to add one package and of course substitute the names of the later packages I am using. But otherwise, line for line, those instructions are dead on. One of the issues is, I am still not entirely sure what the magic button was that got the rtai kernel to recognize multiple processors. Was it using later kernel source code, later rtai code (3.6-cv instead of 3.6.2), changing processors from 2-4 in menuconfig when building the rtai extensions, or some combination thereof. When it finally worked I kind of did all three at once, and at one hour and 40 minutes per build (not counting the time to set everything up each time) it is not going to be fun determining which permutation was the one that made the difference. Regards, Eric Speaking as someone who hasn't really built a kernel, I may be all wet, but to me it looks like there are several chunks to this task: 1) Get a development environment: this includes C compiler, libraries, dependencies, etc. The environment must be compatible with the one on the target machine. To me, this is a strong argument for doing the build on the target machine. That means using the version of GCC and libs that are already on the target machine. 2) Get all the necessary source code. 2a) Kernel source can come from kernel.org, or patched kernels from Debian or Ubuntu. Can be tarballs or apt style source packages. I'm not qualified to comment on which is best, but the version must be compatible with the RTAI source. 2b) RTAI souces - one of about 47 tarballs from https://www.rtai.org/RTAI/, or something from their CVS server at https://gna.org/cvs/?group=rtai << If you go back in this and the other thread, you will see that I asked exactly that. While there was some variation on the responses, the advice I took was to use the latest source for version 2.6.24 (7) on kernel.org. At the time I had not explained my objectives so I can see how there could be multiple "right" answers. A big part of the trial-and-error is picking the right versions of each piece. It seems like you'd want to start with a kernel version that is the same as the "generic" non-RT kernel used by your target system/distro. In this case I think that is the Ubuntu Hardy kernel? 3) Apply the RTAI patches. I have no clue how smoothly (or not) this goes. 4) Configure the kernel - more trial and error. 5) Compile the kernel 6) Test the kernel 7) Package the kernel (optional). I realize that binary packages are easier for other people to use, but the real effort is in steps 1 thru 6. If you (or anyone else) do and document steps 1 through 6, I as a potential user would be happy to repeat the steps following your instructions. If packaging makes your job harder, don't do it. 8) Compile EMC. A binary EMC will only play well with the kernel against which it was compiled. The LinuxCNC team distributes separate binary EMC2 packages for Dapper and Hardy, because there are separate binary kernel packages for Dapper and Hardy. If you have a custom kernel, compiling EMC2 is a given. 9) Package EMC2 (optional). I think this is even less important than step 7. I would be thrilled to be able to follow instructions for steps 1 through 6, and I do step 8 all the time. Looking at my Atom board (hardy installed), the generic kernel package is linux-image-2.6.24-23-generic, version 2.6.24-23.48. The ubuntu repositories have a source package linux-source-2.6.24, apt-get install'ing that should get you the source to rebuild the generic kernel. You can also download the same thing (I think) in tarball form at the bottom of http://packages.ubuntu.com/source/hardy/linux The LinuxCNC realtime kernel is linux-image-2.6.24-16-rtai, and there should be a source package for that as well, but I'm not sure where at the moment. It seems like either of those would be a good starting point. The 2.6.24-16 is known to work with RTAI, but needs reconfigured for SMP. (If I was tackling this, I'd probably start there, and try to reproduce the LinuxCNC non-SMP kernel first.) I may poke at this problem as time permits this week. Unfortunately I can't devote as much time to it as Eric has. ------------------------------------------------------------------------------ Create and Deploy Rich Internet Apps outside the browser with Adobe(R)AIR(TM) software. With Adobe AIR, Ajax developers can use existing skills and code to build responsive, highly engaging applications that combine the power of local resources and data with the reach of the web. Download the Adobe AIR SDK and Ajax docs to start building applications today-http://p.sf.net/sfu/adobe-com _______________________________________________ Emc-developers mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/emc-developers
