Git Product home page Git Product logo

Comments (12)

riebl avatar riebl commented on May 27, 2024

Hi @bargmann,

I am confident that will we be able to fix this issue :-)

  1. Have you checked that all git submodules are properly initalized?
  2. Can you run opp_cmake manually? Try calling ./opp_cmake.py extern/inet/src/Makefile test-inet.cmake from Artery's root directory.
  3. Which version of CMake are you running?
  4. Which Python interpreter (and version) is used (see CMake cache variable PYTHON_EXECUTABLE)?

from artery.

bargmann avatar bargmann commented on May 27, 2024

Hi @riebl,

thanks for your fast answer.
To Point:

  1. I Checked it again and reinstalled some packages. Inet and Veins can be build with make Inet or veins out of the Artery directory. Vanetza can only build irectly out of the Vanetza folder. The build is successful without any problems. With make vanetza out of the artery Vanetza crash with the following error :[ 84%] Linking CXX shared library ../../lib/libvanetza_security.so collect2: fatal error: ld terminated with signal 6 [Abgebrochen], core dumped compilation terminated. /usr/bin/ld: ld: wcsrtombs.c:94: __wcsrtombs: Zusicherung »data.__outbuf[-1] == '\0'« nicht erfüllt. vanetza/security/CMakeFiles/security.dir/build.make:1035: die Regel für Ziel „lib/libvanetza_security.so“ scheiterte make[3]: *** [lib/libvanetza_security.so] Fehler 1 make[3]: *** Datei „lib/libvanetza_security.so“ wird gelöscht make[3]: Verzeichnis „/home/baa4hi/omnest-5.1.1/samples/artery-master/extern/vanetza/build“ wird verlassen CMakeFiles/Makefile2:539: die Regel für Ziel „vanetza/security/CMakeFiles/security.dir/all“ scheiterte make[2]: *** [vanetza/security/CMakeFiles/security.dir/all] Fehler 2 make[2]: Verzeichnis „/home/baa4hi/omnest-5.1.1/samples/artery-master/extern/vanetza/build“ wird verlassen Makefile:127: die Regel für Ziel „all“ scheiterte make[1]: *** [all] Fehler 2 make[1]: Verzeichnis „/home/baa4hi/omnest-5.1.1/samples/artery-master/extern/vanetza/build“ wird verlassen Makefile:47: die Regel für Ziel „vanetza“ scheiterte make: *** [vanetza] Fehler 2

  2. A manually run give also an error with this Log ~/omnest-5.1.1/samples/artery-master$ python ./opp_cmake.py extern/inet/src/Makefile test-inet.cmakeTraceback (most recent call last): File "./opp_cmake.py", line 325, in <module> main() File "./opp_cmake.py", line 317, in main target = parse_opp_makefile(makefile) File "./opp_cmake.py", line 276, in parse_opp_makefile command = extract_makemake_command(makefile) File "./opp_cmake.py", line 291, in extract_makemake_command with open(makefile_path, "r", encoding="utf-8") as makefile: TypeError: 'encoding' is an invalid keyword argument for this function

  3. Cmake Version is 3.5

  4. Python Python 2.7.12 (default, Dec 4 2017, 14:50:18)
    [GCC 5.4.0 20160609] on linux2
    PYTHON_EXECUTABLE:FILEPATH=/usr/bin/python3

from artery.

riebl avatar riebl commented on May 27, 2024
  1. Is your toolchain broken? The printed error message looks like a problem of the linker itself. It is definitely not a "normal build problem" when the linker crashes instead of just reporting an linker error.
  2. python is probably a Python2 interpreter but opp_cmake.py requires Python3. Either let your shell decide on the right interpreter (there is a shebang line in this script) or run it with python3.

from artery.

bargmann avatar bargmann commented on May 27, 2024

Thanks for your fast support. I changed the python interpreter, now i can run the cmake .. without a error. The cmake --build. shows the same error like in 1. I am not so familiar with Ubuntu now. How can I check the toolchain of the linker? Building Vanetza in /extern/vanetza/build shows no error.

from artery.

bargmann avatar bargmann commented on May 27, 2024

I have to correct myself after test make all in artery directory also the build in /extern/vanetza/build shows the error. [ 84%] Linking CXX shared library ../../lib/libvanetza_security.so collect2: fatal error: ld terminated with signal 6 [Abgebrochen], core dumped compilation terminated. /usr/bin/ld: ld: wcsrtombs.c:94: __wcsrtombs: Zusicherung »data.__outbuf[-1] == '\0'« nicht erfüllt. vanetza/security/CMakeFiles/security.dir/build.make:1035: die Regel für Ziel „lib/libvanetza_security.so“ scheiterte make[2]: *** [lib/libvanetza_security.so] Fehler 1 make[2]: *** Datei „lib/libvanetza_security.so“ wird gelöscht CMakeFiles/Makefile2:539: die Regel für Ziel „vanetza/security/CMakeFiles/security.dir/all“ scheiterte make[1]: *** [vanetza/security/CMakeFiles/security.dir/all] Fehler 2 Makefile:127: die Regel für Ziel „all“ scheiterte make: *** [all] Fehler 2

from artery.

bargmann avatar bargmann commented on May 27, 2024

I found out that the build from Vanetza only build the Static lib, everything works fine. The build from Artery want to create the /lib/libvanetza_security.so what is not possible.

from artery.

riebl avatar riebl commented on May 27, 2024

Does any of the CMake variables in Vanetza's build directory refer to a static library (filename *.a)?

from artery.

bargmann avatar bargmann commented on May 27, 2024

In CMakeCache.txt these two static libraries are used.
The Files are available on the system.

CryptoPP_LIBRARY:FILEPATH=/usr/local/lib/libcryptopp.a
GeographicLib_LIBRARY_RELEASE:FILEPATH=/usr/local/lib/libGeographic.a

from artery.

riebl avatar riebl commented on May 27, 2024

I recommend you to rebuild those two libraries as shared objects. Linking static libraries with shared libraries is a source for endless problems, not just with OMNeT++ and Artery but in general.

from artery.

bargmann avatar bargmann commented on May 27, 2024

I the CMakeError.log this failure is printed:

Determining if the pthread_create exist failed with the following output:
Change Dir: /home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp

Run Build Command:"/usr/bin/make" "cmTC_c2003/fast"
make[1]: Verzeichnis „/home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp“ wird betreten
/usr/bin/make -f CMakeFiles/cmTC_c2003.dir/build.make CMakeFiles/cmTC_c2003.dir/build
make[2]: Verzeichnis „/home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp“ wird betreten
Building C object CMakeFiles/cmTC_c2003.dir/CheckSymbolExists.c.o
/usr/bin/cc     -o CMakeFiles/cmTC_c2003.dir/CheckSymbolExists.c.o   -c /home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c
Linking C executable cmTC_c2003
/usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_c2003.dir/link.txt --verbose=1
/usr/bin/cc       CMakeFiles/cmTC_c2003.dir/CheckSymbolExists.c.o  -o cmTC_c2003 -rdynamic 
CMakeFiles/cmTC_c2003.dir/CheckSymbolExists.c.o: In Funktion `main':
CheckSymbolExists.c:(.text+0x16): Nicht definierter Verweis auf `pthread_create'
collect2: error: ld returned 1 exit status
CMakeFiles/cmTC_c2003.dir/build.make:97: die Regel für Ziel „cmTC_c2003“ scheiterte
make[2]: *** [cmTC_c2003] Fehler 1
make[2]: Verzeichnis „/home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp“ wird verlassen
Makefile:126: die Regel für Ziel „cmTC_c2003/fast“ scheiterte
make[1]: *** [cmTC_c2003/fast] Fehler 2
make[1]: Verzeichnis „/home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp“ wird verlassen

File /home/baa4hi/artery/extern/vanetza/build/CMakeFiles/CMakeTmp/CheckSymbolExists.c:
/* */
#include <pthread.h>

int main(int argc, char** argv)
{
  (void)argv;
#ifndef pthread_create
  return ((int*)(&pthread_create))[argc];
#else
  (void)argc;
  return 0;
#endif
}

Has this failure something to do with the shown failure in the shell?
pthread.h is a available file on my system.

from artery.

riebl avatar riebl commented on May 27, 2024

No, CMake is just testing some pthread related settings to find the right set of parameters. If CMake does not fail while generating Makefiles I would not worry about this log entry.

from artery.

bargmann avatar bargmann commented on May 27, 2024

Many Thanks for your fast support.
The missing point was the configuration for the GeoLib, to create also the shared lib. I must install it in this way:

  1. mkdir build && cd build
  2. cmake -D GEOGRAPHICLIB_LIB_TYPE=BOTH ..
  3. make
  4. sudo make install

Now I can build Artery.
The "run_example" is not working at this time, but I think this is an minor issue.
And if not it would be wrong in this topic.

from artery.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.