Problems building Celix on x86_64 Linux
---------------------------------------

                 Key: CELIX-4
                 URL: https://issues.apache.org/jira/browse/CELIX-4
             Project: Celix
          Issue Type: Bug
         Environment: Linux xray 2.6.38-8-generic #42-Ubuntu SMP Mon Apr 11 
03:31:24 UTC 2011 x86_64 x86_64 x86_64 GNU/Linux
            Reporter: Rob ten Hove
            Priority: Minor


Tried building Celix today on 64bit Linux, but encountered two problems:
1) Directory "deployer" is mentioned in /CMakeLists.txt, but doesn't exist:

CMake Error at CMakeLists.txt:63 (add_subdirectory):
  add_subdirectory given source "deployer" which is not an existing
  directory.

2) Running cmake and then make causes linking problems:

Linking C shared library libtracker_depman.so
/usr/bin/ld: 
../../dependency_manager/libdependency_manager.a(service_component.c.o): 
relocation R_X86_64_32S against `service_init' can not be used when making a 
shared object; recompile with -fPIC
../../dependency_manager/libdependency_manager.a: could not read symbols: Bad 
value
collect2: ld returned 1 exit status
make[2]: *** [whiteboard/tracker_depman/libtracker_depman.so] Error 1
make[1]: *** [whiteboard/tracker_depman/CMakeFiles/tracker_depman.dir/all] 
Error 2
make: *** [all] Error 2

Adding a global CFLAGS=-fPIC works, but I guess this is not a feasible 
solution. Building a shared lib instead of a static one for dependency_manager 
works, but don't know if this is feasible too.
Solution that could work is adding a check for the platform for 
dependency_manager, and then specifically adding -fPIC for that lib in case the 
platform is 64bit Unix.
Found the latter suggestion on 
http://www.cmake.org/pipermail/cmake/2007-May/014350.html

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Reply via email to