Building Master

More
12 Feb 2017 12:39 #87867 by Reinhard
Building Master was created by Reinhard
I created a fresh installed VM with debian stable (jessie). There I cloned linuxcnc master.
Then I followed install recommendations from linuxcnc, which means, all dependencies are checked and installed.
in linuxcnc/debian directory I executed the command "./configure uspace rtai" and the following build (dpkg-buildpackage -b -uc) failed with this log:
dh_movefiles
dh_movefiles: debian/tmp//usr/lib/libuspace-rtai.so.0 not found (supposed to put it in linuxcnc-uspace-rtai)
tar: /usr/local/src/linuxcnc/debian/movelist: Funktion stat fehlgeschlagen: Datei oder Verzeichnis nicht gefunden
tar: Error is not recoverable: exiting now
tar: Das sieht nicht wie ein „tar“-Archiv aus.
tar: Beende mit Fehlerstatus aufgrund vorheriger Fehler
dh_movefiles: (cd debian/tmp >/dev/null ; tar --create --files-from=/usr/local/src/linuxcnc/debian/movelist --file -) | (cd debian/linuxcnc-uspace-rtai >/dev/null ;tar xpf -) returned exit code 2
debian/rules:61: recipe for target 'install' failed
make: *** [install] Error 2
dpkg-buildpackage: Fehler: Fehler-Exitstatus von fakeroot debian/rules binary war 2
Then I scanned the build log and there was no attempt to build linuxcnc-uspace-rtai
... but I found a libuspace-xenomai.so.0 in debian/tmp

Are there any recommendations, I might have missed?

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

More
12 Feb 2017 14:38 #87870 by dgarrett
Replied by dgarrett on topic Building Master
If you are trying to make a deb for uspace, try:
./configure uspace

if you are trying to make a deb for rtai, try:
./configure rtai

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

More
12 Feb 2017 16:04 #87872 by Reinhard
Replied by Reinhard on topic Building Master
duh! Should have known that :(
May be it will be helpful to add a vertial line between uspace and rtai

The uspace build fails a bit later:
cp --no-dereference ../lib/liblinuxcncini.so ../lib/libposemath.so ../lib/libnml.so ../lib/libuspace-xenomai.so ../lib/liblinuxcnchal.so ../lib/libcanterp.so ../lib/librs274.so /usr/local/src/linuxcnc/src/../debian/tmp/usr/lib
ldconfig /usr/local/src/linuxcnc/src/../debian/tmp/usr/lib
make[1]: ldconfig: Kommando nicht gefunden
Makefile:573: recipe for target 'install-kernel-indep' failed
make[1]: [install-kernel-indep] Error 127 (ignored)
ldconfig is installed and accessible, but only for root users.
The build should be executed as ordinary user - right?
So may be, adding a sudo in front of ldconfig could solve the problem?

I found the line in linuxcnc/src/Makefile - but as that file is generated, I don't know enuf to patch the right place.

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

More
12 Feb 2017 16:28 #87874 by Reinhard
Replied by Reinhard on topic Building Master
ok - temporarily patching Makefile works, but other errors arise:
sudo ldconfig /usr/local/src/linuxcnc/src/../debian/tmp/usr/lib
ERROR: ld.so: object 'libfakeroot-sysv.so' from LD_PRELOAD cannot be preloaded (cannot open shared object file): ignored.
I guess, later occurring link errors depend on this failure:
dh_shlibdeps -l debian/linuxcnc-uspace/usr/lib
dpkg-shlibdeps: Warnung: Symbol _Z22rtapi_timespec_advanceR8timespecRKS_m, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Symbol rtapi_print_msg, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Symbol task_array, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Symbol _ZN8RtapiApp8get_taskEi, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Symbol _ZN10rtapi_taskC2Ev, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Symbol _ZN8RtapiApp25unexpected_realtime_delayEP10rtapi_taski, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Symbol rtapi_print, verwendet von debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0, in keiner der Bibliotheken gefunden
dpkg-shlibdeps: Warnung: Das Paket könnte eine nutzlose Abhängigkeit vermeiden, falls debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0 nicht gegen libxenomai.so.0 gelinkt wäre (es verwendet keines der Symbole der Bibliothek).
dpkg-shlibdeps: Warnung: Das Paket könnte eine nutzlose Abhängigkeit vermeiden, falls debian/linuxcnc-uspace-xenomai/usr/lib/libuspace-xenomai.so.0 nicht gegen librt.so.1 gelinkt wäre (es verwendet keines der Symbole der Bibliothek).
dpkg-shlibdeps: Fehler: keine Abhängigkeitsinformationen für /var/lib/VBoxGuestAdditions/lib/libGL.so.1 (verwendet von debian/linuxcnc-uspace/usr/lib/python2.7/dist-packages/linuxcnc.x86_64-linux-gnu.so) gefunden

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

More
12 Feb 2017 18:00 - 12 Feb 2017 18:11 #87877 by dgarrett
Replied by dgarrett on topic Building Master
make[1]: ldconfig: Kommando nicht gefunden
Makefile:573: recipe for target 'install-kernel-indep' failed
make[1]: [install-kernel-indep] Error 127 (ignored)
Note: 'ignored'
So there is some other error that you are not showing us i think.

I routinely do the following in a script on debian jessie uspace as a NON-root user:
cd $GIT_ROOT # my root for the git tree (linuxcnc-dev)
cd src
./configure --with-realtime=uspace --enable-build-documentation=html
cd ../debian
./configure uspace
cd ..
time debuild -i -us -uc -b >|1.log 2>|2.log

(I had to install the package for libxenomai-dev)

(you should not have to use sudo or patch the Makefile
for making package; bad things may happen with sudo
that will can have long-term affects)

after reading the configure script, you do not have to install libxenomai-dev if you configure as:
./configure uspace noauto
Last edit: 12 Feb 2017 18:11 by dgarrett.

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

More
12 Feb 2017 18:04 #87879 by PCW
Replied by PCW on topic Building Master
Are these errors possibly because your source directory is not owned by you?
I normally build in ~/linuxcnc-dev but it looks you started in a system directory:

ldconfig /usr/local/src/linuxcnc/src/../debian/tmp/usr/lib

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

More
13 Feb 2017 07:32 #87898 by Reinhard
Replied by Reinhard on topic Building Master
I have to admit, that I'm a linux user only. Not a linux developer.
I'm able to follow build instructions, but I don't know anything about build systems (aside from Makefiles).

@PCW
I consider /usr/local as "my" sandbox, so any software package, that I have to compile, will be extracted to /usr/local/src/<pkg-name>
I never use my home-directory to build system/foreign packages.
If the package uses cmake, I built the package at /usr/local/build (a scratch directory which I created)
Other packages will be build inplace.

I don't own /usr/local/src but group permissions allow to create directories there. When I check out a source package, I do own the package root directory - in this case /usr/local/src/linuxcnc

@dgarret
a call to src/configure is not necessary, as the debian build process calls that script on its own with different arguments.
Your build command looks quite weired. I tried it and it did not work.
... and I don't have a debuild command

@all
I removed the linuxcnc root directory and restarted from scratch with this commands:
cd /usr/local/src
git clone git://git.linuxcnc.org/git/linuxcnc.git linuxcnc
cd linuxcnc/debian
./configure uspace
cd ..
dpkg-checkbuilddeps #// got empty output
dpkg-buildpackage -us -uc -b -tc 2>&1 | tee build-5.log

The active kernel
cat /proc/version
Linux version 4.9.0-0.bpo.1-rt-amd64 (debian-kernel@lists.debian.org) (gcc version 4.9.2 (Debian 4.9.2-10) ) #1 SMP PREEMPT RT Debian 4.9.2-2~bpo8+1 (2017-01-26)

excerpts from dpkg -l
ii  linux-headers-4.9.0-0.bpo.1-common-rt 4.9.2-2~bpo8+1                       all          Common header files for Linux 4.9.0-0.bpo.1-rt
ii  linux-headers-4.9.0-0.bpo.1-rt-amd64  4.9.2-2~bpo8+1                       amd64        Header files for Linux 4.9.0-0.bpo.1-rt-amd64
ii  linux-headers-rt-amd64                4.9+78~bpo8+1                        amd64        Header files for Linux rt-amd64 configuration (meta-package)
ii  linux-image-3.16.0-4-amd64            3.16.39-1                            amd64        Linux 3.16 for 64-bit PCs
ii  linux-image-4.9.0-0.bpo.1-rt-amd64    4.9.2-2~bpo8+1                       amd64        Linux 4.9 for 64-bit PCs, PREEMPT_RT (signed)
ii  linux-image-amd64                     3.16+63                              amd64        Linux for 64-bit PCs (meta-package)
ii  linux-image-rt-amd64                  4.9+78~bpo8+1                        amd64        Linux for 64-bit PCs (meta-package), PREEMPT_RT
ii  linux-kbuild-4.9                      4.9.2-2~bpo8+1                       amd64        Kbuild infrastructure for Linux 4.9
ii  linux-libc-dev:amd64                  4.9.2-2~bpo8+1                       amd64        Linux support headers for userspace development
ii  linux-support-4.9.0-0.bpo.1           4.9.2-2~bpo8+1                       all          Support files for Linux 4.9

The whole buildlog is attached
Attachments:

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

More
13 Feb 2017 07:47 #87899 by Reinhard
Replied by Reinhard on topic Building Master
@dgarret
your recommendations from first reply where wrong.
In debian directory a ./configure uspace works, but a ./configure rtai fails.
A quick look at configure shows this:
Usage:
    $P uspace [noauto | rtai | rtai=packagename | xenomai] ...
        Build for a userspace realtime systems or simulator
...

So my variant ./configure uspace rtai was right ;)

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

More
13 Feb 2017 10:45 #87902 by tommylight
Replied by tommylight on topic Building Master
As far as i know, you can not use rtai on 64 bit systems. From your logs you are using 64 bit kernel.

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

More
13 Feb 2017 12:32 - 13 Feb 2017 12:42 #87904 by Reinhard
Replied by Reinhard on topic Building Master
you are kidding, don't you?

I thought, that every system has already reached 64bit =:O
Ok, I'll check it

//edit says:
Looking at debian/configure line #88ff
# rtai-modules typically doesn't properly declare the architectures where
# it works, so hardcode it...
RTAI_DEV="$(apt-cache search -n rtai-modules | head -1 | awk '{print $1}')"
RTAI_ARCHITECTURE="i386 amd64"
if [ ! -z "$RTAI_DEV" ]; then
    RTAI_DEV="$RTAI_DEV [i386], $RTAI_DEV [amd64]"
fi
So there's amd64 ...
... but on debian stable there are no "rtai-modules" at all
More precise: there is no "rtai-modules" in no release under no section :(
Last edit: 13 Feb 2017 12:42 by Reinhard.

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

Time to create page: 0.146 seconds
Powered by Kunena Forum