Support for uClibC/Linux (OpenWrt 15.05.1 Chaos Calmer)
Hi, I'm interested in setting up build bots for generating uClibC/Linux binaries with cmake-based projects. Unfortunately, I'm having trouble compiling cmake from source on my OpenWrt box. Is there a way to resolve this error, such as by passing additional flags to ./configure
, or are we SOL as a result of OpenWrt Chaos Calmer's gcc lacking pthread support?
Environment:
https://github.com/mcandre/vagrant-openwrt-cmake
Trace:
$ opkg list-installed | grep pthread
libpthread - 0.9.33.2-1
$ ls -Ahl /lib/libpthread.so.0
lrwxrwxrwx 1 root root
$ gcc --version
gcc (OpenWrt GCC 4.8.3) 4.8.3
Copyright (C) 2013 Free Software Foundation, Inc.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
$ ./configure
...
cmSystemTools.o: In function `cmSystemTools::CopyFileTime(char const*, char const*)':
cmSystemTools.cxx:(.text+0x5922): warning: the use of OBSOLESCENT `utime' is discouraged, use `utimes'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_create'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_barrier_wait'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_attr_setstacksize'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_once'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `__pthread_unwind'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_sigmask'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_barrier_init'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_cancel'
/usr/lib/gcc/x86_64-openwrt-linux-uclibc/4.8.3/librt.so: undefined reference to `pthread_detach'
collect2: error: ld returned 1 exit status
---------------------------------------------
Error when bootstrapping CMake:
Problem while running make
---------------------------------------------
make: *** [Makefile:2: cmake] Error 1
Log of errors: /home/vagrant/cmake-3.11.0/Bootstrap.cmk/cmake_bootstrap.log
---------------------------------------------
Edited by Brad King