Hi Arciera,
For test, i removed homemod.so from the rtlib and did :
~/linuxcnc_trajectory_planner/src$ make BUILD_VERBOSE=1
Output of this:
Reading 203/203 dependency files
Done reading dependencies
Reading 266/266 realtime dependency files
Done reading realtime dependencies
Linking ../rtlib/homemod.so
ld -d -r -o objects/homemod.tmp objects/rtemc/motion/homemod.o objects/rtemc/motion/homing.o
objcopy -j .rtapi_export -O binary objects/homemod.tmp objects/homemod.sym
(echo '{ global : '; tr -s '\0' < objects/homemod.sym | xargs -r0 printf '%s;\n' | grep .; echo 'local : * ; };') > objects/homemod.ver
gcc -shared -Bsymbolic -Wl,--version-script,objects/homemod.ver -o ../rtlib/homemod.so objects/rtemc/motion/homemod.o objects/rtemc/motion/homing.o -lm -L/home/user/linuxcnc_trajectory_planner/lib
-Wl,-rpath,/home/user/linuxcnc_trajectory_planner/lib -ltirpc -lgpiod
chmod -x ../rtlib/homemod.so
You now need to run 'sudo make setuid' in order to run in place with access to hardware.
is a prefix used to pass options directly to the linker.
Code:
-rpath,/home/user/linuxcnc_trajectory_planner/lib
sets the runtime library search path for the executable
Now these are added
here
and
here
we have to use
as this is the cmakelists.txt current directory.
Relative from here the filepath is compiled with it.
I hope this solves the problem.