Re: [CMake] undefined reference to `_exit'

2019-02-04 Thread hex
this question a duplicate of [2] I decided to delete it in stackoverflow. Thank you for your help. [1] https://stackoverflow.com/questions/54487747/cmake-undefined-reference-to-exit-while-including-startup-code-as-a-library [2] https://stackoverflow.com/questions/19419782/exit-c-text0x18-undefined

Re: [CMake] undefined reference to `_exit'

2019-02-01 Thread frodak17
If I follow you correctly you are trying to replace the startup files that are normally used with your own versions. You don't mention what the new library is that you are using to replace the startup files. The standard startup files provide _init and _fini. You are also missing _exit which I

Re: [CMake] undefined reference to `_exit'

2019-02-01 Thread Kyle Edwards via CMake
Hex, Can you see what else is in /opt/arm-none-eabi/lib/thumb/v7- ar/fpv3/hard (the same directory as libc.a)? There might be another system library that contains the _exit() implementation that isn't being linked due to your use of the -nostartfiles flag. Kyle On Fri, 2019-02-01 at 22:15 +,

[CMake] undefined reference to `_exit'

2019-02-01 Thread hex
hello, I am trying to include a static library that contains the startup code for ARM processor to my  CMake project for cross compilation. I included the linker script and added it to the executable. Flags and include files are properly set in the CMake build output. The path to the

Re: [CMake] undefined reference to 'pthread_create'

2016-02-04 Thread Rolf Eike Beer
Am Donnerstag, 4. Februar 2016, 10:53:37 schrieb rpela...@archlinux.info: > I believe that doesn't have anything to do with C11 flags. You are just > missing the link to the pthread library. I could be wrong. > > Try and add this to your cmake file: > find_package (Threads) First: >

Re: [CMake] undefined reference to 'pthread_create'

2016-02-04 Thread rpela...@archlinux.info
I believe that doesn't have anything to do with C11 flags. You are just missing the link to the pthread library. I could be wrong. Try and add this to your cmake file: find_package (Threads) target_link_libraries (myexecutable/lib ${CMAKE_THREAD_LIBS_INIT}) Sent from my iPhone > On Feb 4,

[CMake] undefined reference to 'pthread_create'

2016-02-04 Thread Aaron Boxer
Hello, I have a cmake project that uses C++11 threads. I have added the lines set (CMAKE_CXX_STANDARD 14) set(CMAKE_CXX_STANDARD_REQUIRED ON) CMAKE version is 3.2.2, running on Ubuntu. When I try to build, I get the error undefined reference to `pthread_create` Any ideas on how to fix this?

Re: [CMake] undefined reference to 'pthread_create'

2016-02-04 Thread J Decker
Probably didn't previously need pthreads until you updated to use C++11 features which brings in pthreads in the deadstart code... On Thu, Feb 4, 2016 at 8:53 AM, rpela...@archlinux.info wrote: > I believe that doesn't have anything to do with C11 flags. You are just >

Re: [CMake] undefined reference to 'pthread_create'

2016-02-04 Thread Aaron Boxer
Thanks. So, even though threading is part of the standard, I still need to link to pthreads library ? On Thu, Feb 4, 2016 at 11:53 AM, rpela...@archlinux.info < rpela...@archlinux.info> wrote: > I believe that doesn't have anything to do with C11 flags. You are just > missing the link to the

Re: [CMake] undefined reference to 'pthread_create'

2016-02-04 Thread J Decker
On Thu, Feb 4, 2016 at 9:55 AM, Aaron Boxer wrote: > Thanks. So, even though threading is part of the standard, I still need to > link to pthreads library ? Yes; sounds more like an issue for GCC :) I mean you don't have to tell it to link against c library or c++ runtime

Re: [CMake] undefined reference to 'pthread_create'

2016-02-04 Thread Aaron Boxer
Thanks, guys This is working now. Cheers, Aaron On Thu, Feb 4, 2016 at 1:05 PM, J Decker wrote: > On Thu, Feb 4, 2016 at 9:55 AM, Aaron Boxer wrote: > > Thanks. So, even though threading is part of the standard, I still need > to > > link to pthreads

Re: [CMake] Cmake : undefined reference to `udev_device_get_devnode'

2015-11-22 Thread Nikita Barawade
ards, Nikita Barawade Engineer | PES From: Nils Gladitz <nilsglad...@gmail.com> Sent: 20 November 2015 06:34 PM To: Nikita Barawade; cmake@cmake.org Subject: Re: [CMake] Cmake : undefined reference to `udev_device_get_devnode' On 11/20/2015 01:39 PM, Nikita Ba

[CMake] Cmake : undefined reference to `udev_device_get_devnode'

2015-11-20 Thread Nikita Barawade
Dear All, I am building an application using cmake with external shared library libLLAPI.so on Ububtu . I am getting following error: make -f Source/CMakeFiles/app.dir/build.make Source/CMakeFiles/app.dir/build make[2]: Entering directory

Re: [CMake] Cmake : undefined reference to `udev_device_get_devnode'

2015-11-20 Thread Nils Gladitz
On 11/20/2015 01:39 PM, Nikita Barawade wrote: ../../../LLAPI/build/Source/libLLAPI.so: undefined reference to `udev_device_get_devnode' Before this, while buildinga library libLLAPI.so I got error " fatal error: libudev.h: No such file or directory" . It worked fine after installing

Re: [CMake] undefined reference to error when use c extension

2015-06-05 Thread J Decker
Or make c++ wrappers that use dlopen/dlsym or loadlibrary/getprocaddress as appropriate and reference the libs through an interface class. On Fri, Jun 5, 2015 at 7:44 PM, J Decker d3c...@gmail.com wrote: it's not the lib, it's the header interface to the lib. On Fri, Jun 5, 2015 at 7:42 PM,

Re: [CMake] undefined reference to error when use c extension

2015-06-05 Thread Sunrise
Thanks for your reply. I am aware of extern C {} but this is not an option for me. As I mentioned, there are a lot of lib files (which were not written by me) and I was wondering if lib itself could be untouched. On 06/05/2015 07:33 PM, J Decker wrote: c++ does name mangling on functions... so

Re: [CMake] undefined reference to error when use c extension

2015-06-05 Thread J Decker
c++ does name mangling on functions... so functions like 'f' become a much more complex name (as shown in the xxx not found in your error messages). In order for C++ to not produce a mangled name C functions have to be defined as extern c void f( void ); but 'extern c' is not liked by C... so you

Re: [CMake] undefined reference to error when use c extension

2015-06-05 Thread Greg Marr
From: J Decker d3c...@gmail.com Date: 06/05/2015 10:33 PM (GMT-05:00) To: Sunrise helios.cor...@gmail.com Cc: cmake@cmake.org Subject: Re: [CMake] undefined reference to error when use c extension c++ does name mangling on functions... so functions like 'f' become a much more complex name

Re: [CMake] undefined reference to error when use c extension

2015-06-05 Thread J Decker
it's not the lib, it's the header interface to the lib. On Fri, Jun 5, 2015 at 7:42 PM, Sunrise helios.cor...@gmail.com wrote: Thanks for your reply. I am aware of extern C {} but this is not an option for me. As I mentioned, there are a lot of lib files (which were not written by me) and I

[CMake] undefined reference to symbol 'keypad'

2013-05-03 Thread Matteo Parsani
Dear All, I am trying to compile cmake 2.8.10 on a computer with the following operating system: /opt/centos/devtoolset-1.1/root/usr/libexec/gcc/x86_64-redhat-linux/4.7.2/ld: note: 'keypad' is defined in DSO /lib64/libtinfo.so.5 so try adding it to the linker command line /lib64/libtinfo.so.5:

Re: [CMake] Undefined reference

2011-11-04 Thread Hendrik Sattler
Am 03.11.2011 15:51, schrieb Mauricio Klein: Thank you Raphael, it worked! One last question: i've tried to compile my code using static linkage, once i need my daemon runs in many Linux releases. But, even static, in many systems my code crashes because the GLIBC version. My question is:

Re: [CMake] Undefined reference

2011-11-04 Thread Mauricio Klein
I see. Well, i will research about package managers to perform this tasks automatically. Better than manipulate libraries myself. Thanks guys for every reply sent! On Fri, Nov 4, 2011 at 5:00 AM, Hendrik Sattler p...@hendrik-sattler.dewrote: Am 03.11.2011 15:51, schrieb Mauricio Klein:

Re: [CMake] Undefined reference

2011-11-04 Thread Michael Hertling
On 11/04/2011 12:50 AM, Dan Kegel wrote: On Thu, Nov 3, 2011 at 4:16 PM, Michael Hertling mhertl...@online.de wrote: Static linking of glibc is not really supported; IIRC glibc's DNS and localization support use shared libraries under the hood, even when you ask for static linking

[CMake] Undefined reference

2011-11-03 Thread Mauricio Klein
Hello guys! I'm new in CMake world, and i'm trying to compile a daemon developed a log time ago. I can compile all my codes without problems, but in the linkage step, i receive a lot of errors about undefined reference to OpenSSL functions (yes, my code uses OpenSSL). In my own (and ugly :P)

Re: [CMake] Undefined reference

2011-11-03 Thread Matt Williams
On 3 November 2011 15:12, Mauricio Klein mauricio.klein@gmail.com wrote: Hello guys! I'm new in CMake world, and i'm trying to compile a daemon developed a log time ago. I can compile all my codes without problems, but in the linkage step, i receive a lot of errors about undefined

Re: [CMake] Undefined reference

2011-11-03 Thread Raphael Kubo da Costa
Mauricio Klein mauricio.klein@gmail.com writes: I can compile all my codes without problems, but in the linkage step, i receive a lot of errors about undefined reference to OpenSSL functions (yes, my code uses OpenSSL). In my own (and ugly :P) Makefile, i use -lssl flag in g++ compile

Re: [CMake] Undefined reference

2011-11-03 Thread Mauricio Klein
Thank you Raphael, it worked! One last question: i've tried to compile my code using static linkage, once i need my daemon runs in many Linux releases. But, even static, in many systems my code crashes because the GLIBC version. My question is: asking for static linkage in CMake can solve this

Re: [CMake] Undefined reference

2011-11-03 Thread Michael Hertling
On 11/03/2011 03:51 PM, Mauricio Klein wrote: Thank you Raphael, it worked! One last question: i've tried to compile my code using static linkage, once i need my daemon runs in many Linux releases. But, even static, in many systems my code crashes because the GLIBC version. How do these

Re: [CMake] Undefined reference

2011-11-03 Thread Mauricio Klein
The error reported occurs in the launch time: the daemon doesn't starts and report (in terminal) a GLIBC version error. I mean, the daemon was compiled in a old CentOS (4.8) and i'm trying to run in the latest Ubuntu. But anyway, i will make more tests as you sugested and try to discovery what

Re: [CMake] Undefined reference

2011-11-03 Thread Michael Hertling
On 11/03/2011 06:20 PM, Mauricio Klein wrote: The error reported occurs in the launch time: the daemon doesn't starts and report (in terminal) a GLIBC version error. [...] Usually, this means that it has *not* been linked statically against the GLIBC on the build system. Which dependencies does

Re: [CMake] Undefined reference

2011-11-03 Thread Mauricio Klein
ldd reports that is not dynamically executable, as expected. But even ldd saying that, the problem with GLIBC occurs. On Thu, Nov 3, 2011 at 3:33 PM, Michael Hertling mhertl...@online.dewrote: On 11/03/2011 06:20 PM, Mauricio Klein wrote: The error reported occurs in the launch time: the

Re: [CMake] Undefined reference

2011-11-03 Thread Michael Hertling
On 11/03/2011 06:39 PM, Mauricio Klein wrote: ldd reports that is not dynamically executable, as expected. But even ldd saying that, the problem with GLIBC occurs. What exactly does ldd report, and how exactly the executable is linked? Regards, Michael On Thu, Nov 3, 2011 at 3:33 PM,

Re: [CMake] Undefined reference

2011-11-03 Thread Dan Kegel
On Thu, Nov 3, 2011 at 7:51 AM, Mauricio Klein mauricio.klein@gmail.com wrote: One last question: i've tried to compile my code using static linkage, once i need my daemon runs in many Linux releases. Static linking of glibc is not really supported; IIRC glibc's DNS and localization support

Re: [CMake] Undefined reference

2011-11-03 Thread Michael Hertling
On 11/03/2011 10:18 PM, Dan Kegel wrote: On Thu, Nov 3, 2011 at 7:51 AM, Mauricio Klein mauricio.klein@gmail.com wrote: One last question: i've tried to compile my code using static linkage, once i need my daemon runs in many Linux releases. Static linking of glibc is not really

Re: [CMake] Undefined reference

2011-11-03 Thread Dan Kegel
On Thu, Nov 3, 2011 at 4:16 PM, Michael Hertling mhertl...@online.de wrote: Static linking of glibc is not really supported; IIRC glibc's DNS and localization support use shared libraries under the hood, even when you ask for static linking [statically linked utilities are essential for

Re: [CMake] Undefined reference to __Unwind_Resume when building a universal binary with make on Mac OS X

2010-09-13 Thread Ryan Pavlik
if(APPLE) set(CMAKE_OSX_DEPLOYMENT_TARGET 10.5) endif() Hope this helps! Ryan On 9/10/10 9:19 AM, Pedro d'Aquino wrote: The problem wasn't related to the universal binaries, but to the SDK used (10.5). I need to add -mmacosx-version-min=10.5 to the compiler flags in order to make it

[CMake] Undefined reference to __Unwind_Resume when building a universal binary with make on Mac OS X

2010-09-10 Thread Pedro d'Aquino
Hi everyone, I'm currently modifying an existing CMake-based project to build universal binaries on 10.6.4. Xcode 3.2.3 builds the new project fine, but the make-based compilation fails because of an undefined symbol, __Unwind_Resume. The actual command used for compiling each C++ file is (from

Re: [CMake] Undefined reference to __Unwind_Resume when building a universal binary with make on Mac OS X

2010-09-10 Thread Pedro d'Aquino
The problem wasn't related to the universal binaries, but to the SDK used (10.5). I need to add -mmacosx-version-min=10.5 to the compiler flags in order to make it work. Shouldn't this be handled automatically by CMake? On Fri, Sep 10, 2010 at 8:46 AM, Pedro d'Aquino bud...@gmail.com wrote: Hi

[CMake] undefined reference error

2007-10-22 Thread Paulo Henrique Junqueira Amorim
Hello, I am generating wrapper python linux of the vtk class with slicer3d class. The cmake generate files to compile but when make comand are ocurred error: /VTK/bin/libvtkImaging.so: undefined reference to `vtkImageThresholdBeyond::New() As I define references ? It

Re: [CMake] undefined reference to memcpy ?

2006-06-13 Thread Alexander Neundorf
Von: Alexander Neundorf [EMAIL PROTECTED] Hi, I have three libraries here, libA, libB and libC. All three are linked as shared libs. libB and libC are written in C++ but have a C interface, libA is completely C. When trying to link libC, which links to libB, which links to libA I get

[CMake] undefined reference to memcpy ?

2006-06-12 Thread Alexander Neundorf
Hi, I have three libraries here, libA, libB and libC. All three are linked as shared libs. libB and libC are written in C++ but have a C interface, libA is completely C. When trying to link libC, which links to libB, which links to libA I get undefined references to memcpy (but only from one