* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
@ 2018-08-22 21:58 Baruch Siach
2018-08-22 22:09 ` Yann E. MORIN
` (3 more replies)
0 siblings, 4 replies; 9+ messages in thread
From: Baruch Siach @ 2018-08-22 21:58 UTC (permalink / raw)
To: buildroot
Old version of cmake break cross-compilation when FindThreads is used
because of a try_run call. Add a workaround that avoids try_run.
cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
Should fix:
http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
Cc: Scott Fan <fancp2007@gmail.com>
Signed-off-by: Baruch Siach <baruch@tkos.co.il>
---
Hi Peter, Yann,
Can one of you test this fix on one of the affected autobuilders?
http://autobuild.buildroot.net/?reason=libssh-0.8.1
Thanks,
baruch
---
package/libssh/libssh.mk | 3 +++
1 file changed, 3 insertions(+)
diff --git a/package/libssh/libssh.mk b/package/libssh/libssh.mk
index 4295aa42ee3b..635d72ad9868 100644
--- a/package/libssh/libssh.mk
+++ b/package/libssh/libssh.mk
@@ -17,6 +17,9 @@ LIBSSH_CONF_OPTS = \
-DWITH_SERVER=OFF \
-DWITH_EXAMPLES=OFF
+# cmake older than 3.10 require this to avoid try_run() in FindThreads
+LIBSSH_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
+
ifeq ($(BR2_PACKAGE_ZLIB),y)
LIBSSH_CONF_OPTS += -DWITH_ZLIB=ON
LIBSSH_DEPENDENCIES += zlib
--
2.18.0
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-22 21:58 [Buildroot] [PATCH] libssh: fix cross compile with older cmake Baruch Siach
@ 2018-08-22 22:09 ` Yann E. MORIN
2018-08-22 22:27 ` Yann E. MORIN
2018-08-23 9:24 ` Jan Kundrát
` (2 subsequent siblings)
3 siblings, 1 reply; 9+ messages in thread
From: Yann E. MORIN @ 2018-08-22 22:09 UTC (permalink / raw)
To: buildroot
Bruch, All,
On 2018-08-23 00:58 +0300, Baruch Siach spake thusly:
> Old version of cmake break cross-compilation when FindThreads is used
> because of a try_run call. Add a workaround that avoids try_run.
>
> cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
>
> Should fix:
> http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
> http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
>
> Cc: Scott Fan <fancp2007@gmail.com>
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> ---
> Hi Peter, Yann,
>
> Can one of you test this fix on one of the affected autobuilders?
>
> http://autobuild.buildroot.net/?reason=libssh-0.8.1
My autobuilder does not have cmake installed, so will use or own
host-cmake, as can be seen in the failure on my autobuilder:
http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/build-end.log
[...] /home/buildroot/autobuild/run/instance-3/output/host/bin/cmake [...]
So I guess you can test on a machine that does not have cmake installed.
But I'll spin a test on my autobuilder in a moment, and report back...
Regards,
Yann E. MORIN.
> Thanks,
> baruch
> ---
> package/libssh/libssh.mk | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/package/libssh/libssh.mk b/package/libssh/libssh.mk
> index 4295aa42ee3b..635d72ad9868 100644
> --- a/package/libssh/libssh.mk
> +++ b/package/libssh/libssh.mk
> @@ -17,6 +17,9 @@ LIBSSH_CONF_OPTS = \
> -DWITH_SERVER=OFF \
> -DWITH_EXAMPLES=OFF
>
> +# cmake older than 3.10 require this to avoid try_run() in FindThreads
> +LIBSSH_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
> +
> ifeq ($(BR2_PACKAGE_ZLIB),y)
> LIBSSH_CONF_OPTS += -DWITH_ZLIB=ON
> LIBSSH_DEPENDENCIES += zlib
> --
> 2.18.0
>
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-22 22:09 ` Yann E. MORIN
@ 2018-08-22 22:27 ` Yann E. MORIN
2018-08-23 3:42 ` Baruch Siach
0 siblings, 1 reply; 9+ messages in thread
From: Yann E. MORIN @ 2018-08-22 22:27 UTC (permalink / raw)
To: buildroot
Baruch, All,
On 2018-08-23 00:09 +0200, Yann E. MORIN spake thusly:
> On 2018-08-23 00:58 +0300, Baruch Siach spake thusly:
> > Old version of cmake break cross-compilation when FindThreads is used
> > because of a try_run call. Add a workaround that avoids try_run.
> >
> > cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
> >
> > Should fix:
> > http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
> > http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
> >
> > Cc: Scott Fan <fancp2007@gmail.com>
> > Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> > ---
> > Hi Peter, Yann,
> >
> > Can one of you test this fix on one of the affected autobuilders?
> >
> > http://autobuild.buildroot.net/?reason=libssh-0.8.1
>
> My autobuilder does not have cmake installed, so will use or own
> host-cmake, as can be seen in the failure on my autobuilder:
> http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/build-end.log
>
> [...] /home/buildroot/autobuild/run/instance-3/output/host/bin/cmake [...]
>
> So I guess you can test on a machine that does not have cmake installed.
>
> But I'll spin a test on my autobuilder in a moment, and report back...
Here are the results of the configure step, using the config from my
autobuilder referenced above, and running 'make libssh-depends' first:
---8<---
$ make libssh-configure
umask 0022 && make -C /home/buildroot/dev/buildroot O=/home/buildroot/dev/O/. libssh-configure
libssh-0.7.5.tar.xz: OK (md5: d3fc864208bf607ad87cdee836894feb)
libssh-0.7.5.tar.xz: OK (sha256: 54e86dd5dc20e5367e58f3caab337ce37675f863f80df85b6b1614966a337095)
>>> libssh 0.7.5 Extracting
xzcat /home/buildroot/src/libssh/libssh-0.7.5.tar.xz | tar --strip-components=1 -C /home/buildroot/dev/O/build/libssh-0.7.5 -xf -
>>> libssh 0.7.5 Patching
>>> libssh 0.7.5 Configuring
(mkdir -p /home/buildroot/dev/O/build/libssh-0.7.5//buildroot-build && cd /home/buildroot/dev/O/build/libssh-0.7.5//buildroot-build && rm -f CMakeCache.txt && PATH="/home/buildroot/dev/O/host/bin:/home/buildroot/dev/O/host/sbin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games" /home/buildroot/dev/O/host/bin/cmake /home/buildroot/dev/O/build/libssh-0.7.5/ -DCMAKE_TOOLCHAIN_FILE="/home/buildroot/dev/O/host/share/buildroot/toolchainfile.cmake" -DCMAKE_INSTALL_PREFIX="/usr" -DCMAKE_COLOR_MAKEFILE=OFF -DBUILD_DOC=OFF -DBUILD_DOCS=OFF -DBUILD_EXAMPLE=OFF -DBUILD_EXAMPLES=OFF -DBUILD_TEST=OFF -DBUILD_TESTS=OFF -DBUILD_TESTING=OFF -DBUILD_SHARED_LIBS=ON -DWITH_STACK_PROTECTOR=OFF -DWITH_SERVER=OFF -DWITH_EXAMPLES=OFF -DTHREADS_PTHREAD_ARG=OFF -DWITH_ZLIB=ON -DWITH_GCRYPT=OFF )
-- The C compiler identification is GNU 6.4.0
-- Check for working C compiler: /home/buildroot/dev/O/host/bin/mipsel-linux-gcc
-- Check for working C compiler: /home/buildroot/dev/O/host/bin/mipsel-linux-gcc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Performing Test WITH_FPIC
-- Performing Test WITH_FPIC - Success
-- Found ZLIB: /home/buildroot/dev/O/host/mipsel-buildroot-linux-gnu/sysroot/usr/lib/libz.so (found version "1.2.11")
-- Found OpenSSL: /home/buildroot/dev/O/host/mipsel-buildroot-linux-gnu/sysroot/usr/lib/libcrypto.so (found version "1.0.2p")
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Looking for pthread_create
-- Looking for pthread_create - not found
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found PkgConfig: /home/buildroot/dev/O/host/bin/pkg-config (found version "0.28")
-- Checking for module 'heimdal-gssapi'
-- Package heimdal-gssapi was not found in the pkg-config search path.
Perhaps you should add the directory containing `heimdal-gssapi.pc'
to the PKG_CONFIG_PATH environment variable
Package 'heimdal-gssapi', required by 'world', not found
-- Could NOT find GSSAPI (missing: GSSAPI_LIBRARIES GSSAPI_INCLUDE_DIR)
-- Could NOT find NaCl (missing: NACL_LIBRARIES NACL_INCLUDE_DIRS)
-- Performing Test WITH_VISIBILITY_HIDDEN
-- Performing Test WITH_VISIBILITY_HIDDEN - Success
-- Looking for argp.h
-- Looking for argp.h - found
-- Looking for pty.h
-- Looking for pty.h - found
-- Looking for utmp.h
-- Looking for utmp.h - found
-- Looking for termios.h
-- Looking for termios.h - found
-- Looking for unistd.h
-- Looking for unistd.h - found
-- Looking for util.h
-- Looking for util.h - not found
-- Looking for libutil.h
-- Looking for libutil.h - not found
-- Looking for sys/time.h
-- Looking for sys/time.h - found
-- Looking for sys/param.h
-- Looking for sys/param.h - found
-- Looking for arpa/inet.h
-- Looking for arpa/inet.h - found
-- Looking for byteswap.h
-- Looking for byteswap.h - found
-- Looking for openssl/des.h
-- Looking for openssl/des.h - found
-- Looking for openssl/aes.h
-- Looking for openssl/aes.h - found
-- Looking for openssl/blowfish.h
-- Looking for openssl/blowfish.h - found
-- Looking for openssl/ecdh.h
-- Looking for openssl/ecdh.h - found
-- Looking for openssl/ec.h
-- Looking for openssl/ec.h - found
-- Looking for openssl/ecdsa.h
-- Looking for openssl/ecdsa.h - found
-- Looking for isblank
-- Looking for isblank - found
-- Looking for strncpy
-- Looking for strncpy - found
-- Looking for strtoull
-- Looking for strtoull - found
-- Looking for vsnprintf
-- Looking for vsnprintf - found
-- Looking for snprintf
-- Looking for snprintf - found
-- Looking for poll
-- Looking for poll - found
-- Looking for select
-- Looking for select - found
-- Looking for getaddrinfo
-- Looking for getaddrinfo - found
-- Looking for ntohll
-- Looking for ntohll - not found
-- Looking for htonll
-- Looking for htonll - not found
-- Looking for clock_gettime in rt
-- Looking for clock_gettime in rt - found
-- Looking for forkpty in util
-- Looking for forkpty in util - found
-- Looking for cfmakeraw
-- Looking for cfmakeraw - found
-- Looking for __strtoull
-- Looking for __strtoull - not found
-- Performing Test HAVE_GCC_THREAD_LOCAL_STORAGE
-- Performing Test HAVE_GCC_THREAD_LOCAL_STORAGE - Success
-- Performing Test HAVE_MSC_THREAD_LOCAL_STORAGE
-- Performing Test HAVE_MSC_THREAD_LOCAL_STORAGE - Failed
-- Performing Test HAVE_GCC_VOLATILE_MEMORY_PROTECTION
-- Performing Test HAVE_GCC_VOLATILE_MEMORY_PROTECTION - Success
-- Performing Test HAVE_GCC_NARG_MACRO
-- Performing Test HAVE_GCC_NARG_MACRO - Success
-- Performing Test HAVE_COMPILER__FUNC__
-- Performing Test HAVE_COMPILER__FUNC__ - Success
-- Performing Test HAVE_COMPILER__FUNCTION__
-- Performing Test HAVE_COMPILER__FUNCTION__ - Failed
-- Check if the system is big endian
-- Searching 16 bit integer
-- Looking for sys/types.h
-- Looking for sys/types.h - found
-- Looking for stdint.h
-- Looking for stdint.h - found
-- Looking for stddef.h
-- Looking for stddef.h - found
-- Check size of unsigned short
-- Check size of unsigned short - done
-- Using unsigned short
-- Check if the system is big endian - little endian
-- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
-- Threads_FOUND=TRUE
-- threads library: Threads_FOUND=TRUE
-- libssh_threads_SRCS=pthread.c
-- ********************************************
-- ********** libssh build options : **********
-- zlib support: ON
-- libgcrypt support: OFF
-- libnacl support: OFF
-- SSH-1 support: OFF
-- SFTP support: ON
-- Server support : OFF
-- GSSAPI support : 0
-- Pcap debugging support : ON
-- With static library: OFF
-- Unit testing: OFF
-- Client code Unit testing: OFF
-- Public API documentation generation
-- Benchmarks: OFF
-- ********************************************
-- Configuring done
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:
BUILD_DOC
BUILD_DOCS
BUILD_EXAMPLE
BUILD_EXAMPLES
BUILD_TEST
BUILD_TESTING
BUILD_TESTS
THREADS_PTHREAD_ARG
-- Build files have been written to: /home/buildroot/dev/O/build/libssh-0.7.5/buildroot-build
---8<---
The build step was then successfull, by the way...
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-22 22:27 ` Yann E. MORIN
@ 2018-08-23 3:42 ` Baruch Siach
2018-08-23 6:39 ` Yann E. MORIN
0 siblings, 1 reply; 9+ messages in thread
From: Baruch Siach @ 2018-08-23 3:42 UTC (permalink / raw)
To: buildroot
Hi Yann,
Yann E. MORIN writes:
> On 2018-08-23 00:09 +0200, Yann E. MORIN spake thusly:
>> On 2018-08-23 00:58 +0300, Baruch Siach spake thusly:
>> > Old version of cmake break cross-compilation when FindThreads is used
>> > because of a try_run call. Add a workaround that avoids try_run.
>> >
>> > cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
>> >
>> > Should fix:
>> > http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
>> > http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
>> >
>> > Cc: Scott Fan <fancp2007@gmail.com>
>> > Signed-off-by: Baruch Siach <baruch@tkos.co.il>
>> > ---
>> > Hi Peter, Yann,
>> >
>> > Can one of you test this fix on one of the affected autobuilders?
>> >
>> > http://autobuild.buildroot.net/?reason=libssh-0.8.1
>>
>> My autobuilder does not have cmake installed, so will use or own
>> host-cmake, as can be seen in the failure on my autobuilder:
>> http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/build-end.log
>>
>> [...] /home/buildroot/autobuild/run/instance-3/output/host/bin/cmake [...]
>>
>> So I guess you can test on a machine that does not have cmake
>> installed.
Right. I assumed that Buildroot has the latest, newer than 3.10,
cmake. But this is evidently not true. Commit log of 5b57ae7ad197
(Revert "package/cmake: bump version to 3.10.0 and add license hash")
seems to indicate that we'll have to wait a while for the next cmake
version bump.
>> But I'll spin a test on my autobuilder in a moment, and report
>> back...
Thanks.
> Here are the results of the configure step, using the config from my
> autobuilder referenced above, and running 'make libssh-depends' first:
You meant to say 'make libssh-configure' here, right?
So I reproduced the build failure and the fix with host-cmake here as
well.
Thanks,
baruch
> ---8<---
>
> $ make libssh-configure
> umask 0022 && make -C /home/buildroot/dev/buildroot O=/home/buildroot/dev/O/. libssh-configure
> libssh-0.7.5.tar.xz: OK (md5: d3fc864208bf607ad87cdee836894feb)
> libssh-0.7.5.tar.xz: OK (sha256: 54e86dd5dc20e5367e58f3caab337ce37675f863f80df85b6b1614966a337095)
>>>> libssh 0.7.5 Extracting
> xzcat /home/buildroot/src/libssh/libssh-0.7.5.tar.xz | tar --strip-components=1 -C /home/buildroot/dev/O/build/libssh-0.7.5 -xf -
>>>> libssh 0.7.5 Patching
>>>> libssh 0.7.5 Configuring
> (mkdir -p /home/buildroot/dev/O/build/libssh-0.7.5//buildroot-build && cd /home/buildroot/dev/O/build/libssh-0.7.5//buildroot-build && rm -f CMakeCache.txt && PATH="/home/buildroot/dev/O/host/bin:/home/buildroot/dev/O/host/sbin:/usr/local/bin:/usr/bin:/bin:/usr/local/games:/usr/games" /home/buildroot/dev/O/host/bin/cmake /home/buildroot/dev/O/build/libssh-0.7.5/ -DCMAKE_TOOLCHAIN_FILE="/home/buildroot/dev/O/host/share/buildroot/toolchainfile.cmake" -DCMAKE_INSTALL_PREFIX="/usr" -DCMAKE_COLOR_MAKEFILE=OFF -DBUILD_DOC=OFF -DBUILD_DOCS=OFF -DBUILD_EXAMPLE=OFF -DBUILD_EXAMPLES=OFF -DBUILD_TEST=OFF -DBUILD_TESTS=OFF -DBUILD_TESTING=OFF -DBUILD_SHARED_LIBS=ON -DWITH_STACK_PROTECTOR=OFF -DWITH_SERVER=OFF -DWITH_EXAMPLES=OFF -DTHREADS_PTHREAD_ARG=OFF -DWITH_ZLIB=ON -DWITH_GCRYPT=OFF )
> -- The C compiler identification is GNU 6.4.0
> -- Check for working C compiler: /home/buildroot/dev/O/host/bin/mipsel-linux-gcc
> -- Check for working C compiler: /home/buildroot/dev/O/host/bin/mipsel-linux-gcc -- works
> -- Detecting C compiler ABI info
> -- Detecting C compiler ABI info - done
> -- Detecting C compile features
> -- Detecting C compile features - done
> -- Performing Test WITH_FPIC
> -- Performing Test WITH_FPIC - Success
> -- Found ZLIB: /home/buildroot/dev/O/host/mipsel-buildroot-linux-gnu/sysroot/usr/lib/libz.so (found version "1.2.11")
> -- Found OpenSSL: /home/buildroot/dev/O/host/mipsel-buildroot-linux-gnu/sysroot/usr/lib/libcrypto.so (found version "1.0.2p")
> -- Looking for pthread.h
> -- Looking for pthread.h - found
> -- Looking for pthread_create
> -- Looking for pthread_create - not found
> -- Looking for pthread_create in pthreads
> -- Looking for pthread_create in pthreads - not found
> -- Looking for pthread_create in pthread
> -- Looking for pthread_create in pthread - found
> -- Found Threads: TRUE
> -- Found PkgConfig: /home/buildroot/dev/O/host/bin/pkg-config (found version "0.28")
> -- Checking for module 'heimdal-gssapi'
> -- Package heimdal-gssapi was not found in the pkg-config search path.
> Perhaps you should add the directory containing `heimdal-gssapi.pc'
> to the PKG_CONFIG_PATH environment variable
> Package 'heimdal-gssapi', required by 'world', not found
> -- Could NOT find GSSAPI (missing: GSSAPI_LIBRARIES GSSAPI_INCLUDE_DIR)
> -- Could NOT find NaCl (missing: NACL_LIBRARIES NACL_INCLUDE_DIRS)
> -- Performing Test WITH_VISIBILITY_HIDDEN
> -- Performing Test WITH_VISIBILITY_HIDDEN - Success
> -- Looking for argp.h
> -- Looking for argp.h - found
> -- Looking for pty.h
> -- Looking for pty.h - found
> -- Looking for utmp.h
> -- Looking for utmp.h - found
> -- Looking for termios.h
> -- Looking for termios.h - found
> -- Looking for unistd.h
> -- Looking for unistd.h - found
> -- Looking for util.h
> -- Looking for util.h - not found
> -- Looking for libutil.h
> -- Looking for libutil.h - not found
> -- Looking for sys/time.h
> -- Looking for sys/time.h - found
> -- Looking for sys/param.h
> -- Looking for sys/param.h - found
> -- Looking for arpa/inet.h
> -- Looking for arpa/inet.h - found
> -- Looking for byteswap.h
> -- Looking for byteswap.h - found
> -- Looking for openssl/des.h
> -- Looking for openssl/des.h - found
> -- Looking for openssl/aes.h
> -- Looking for openssl/aes.h - found
> -- Looking for openssl/blowfish.h
> -- Looking for openssl/blowfish.h - found
> -- Looking for openssl/ecdh.h
> -- Looking for openssl/ecdh.h - found
> -- Looking for openssl/ec.h
> -- Looking for openssl/ec.h - found
> -- Looking for openssl/ecdsa.h
> -- Looking for openssl/ecdsa.h - found
> -- Looking for isblank
> -- Looking for isblank - found
> -- Looking for strncpy
> -- Looking for strncpy - found
> -- Looking for strtoull
> -- Looking for strtoull - found
> -- Looking for vsnprintf
> -- Looking for vsnprintf - found
> -- Looking for snprintf
> -- Looking for snprintf - found
> -- Looking for poll
> -- Looking for poll - found
> -- Looking for select
> -- Looking for select - found
> -- Looking for getaddrinfo
> -- Looking for getaddrinfo - found
> -- Looking for ntohll
> -- Looking for ntohll - not found
> -- Looking for htonll
> -- Looking for htonll - not found
> -- Looking for clock_gettime in rt
> -- Looking for clock_gettime in rt - found
> -- Looking for forkpty in util
> -- Looking for forkpty in util - found
> -- Looking for cfmakeraw
> -- Looking for cfmakeraw - found
> -- Looking for __strtoull
> -- Looking for __strtoull - not found
> -- Performing Test HAVE_GCC_THREAD_LOCAL_STORAGE
> -- Performing Test HAVE_GCC_THREAD_LOCAL_STORAGE - Success
> -- Performing Test HAVE_MSC_THREAD_LOCAL_STORAGE
> -- Performing Test HAVE_MSC_THREAD_LOCAL_STORAGE - Failed
> -- Performing Test HAVE_GCC_VOLATILE_MEMORY_PROTECTION
> -- Performing Test HAVE_GCC_VOLATILE_MEMORY_PROTECTION - Success
> -- Performing Test HAVE_GCC_NARG_MACRO
> -- Performing Test HAVE_GCC_NARG_MACRO - Success
> -- Performing Test HAVE_COMPILER__FUNC__
> -- Performing Test HAVE_COMPILER__FUNC__ - Success
> -- Performing Test HAVE_COMPILER__FUNCTION__
> -- Performing Test HAVE_COMPILER__FUNCTION__ - Failed
> -- Check if the system is big endian
> -- Searching 16 bit integer
> -- Looking for sys/types.h
> -- Looking for sys/types.h - found
> -- Looking for stdint.h
> -- Looking for stdint.h - found
> -- Looking for stddef.h
> -- Looking for stddef.h - found
> -- Check size of unsigned short
> -- Check size of unsigned short - done
> -- Using unsigned short
> -- Check if the system is big endian - little endian
> -- Could NOT find Doxygen (missing: DOXYGEN_EXECUTABLE)
> -- Threads_FOUND=TRUE
> -- threads library: Threads_FOUND=TRUE
> -- libssh_threads_SRCS=pthread.c
> -- ********************************************
> -- ********** libssh build options : **********
> -- zlib support: ON
> -- libgcrypt support: OFF
> -- libnacl support: OFF
> -- SSH-1 support: OFF
> -- SFTP support: ON
> -- Server support : OFF
> -- GSSAPI support : 0
> -- Pcap debugging support : ON
> -- With static library: OFF
> -- Unit testing: OFF
> -- Client code Unit testing: OFF
> -- Public API documentation generation
> -- Benchmarks: OFF
> -- ********************************************
> -- Configuring done
> -- Generating done
> CMake Warning:
> Manually-specified variables were not used by the project:
>
> BUILD_DOC
> BUILD_DOCS
> BUILD_EXAMPLE
> BUILD_EXAMPLES
> BUILD_TEST
> BUILD_TESTING
> BUILD_TESTS
> THREADS_PTHREAD_ARG
>
>
> -- Build files have been written to: /home/buildroot/dev/O/build/libssh-0.7.5/buildroot-build
>
> ---8<---
>
> The build step was then successfull, by the way...
>
> Regards,
> Yann E. MORIN.
--
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-23 3:42 ` Baruch Siach
@ 2018-08-23 6:39 ` Yann E. MORIN
0 siblings, 0 replies; 9+ messages in thread
From: Yann E. MORIN @ 2018-08-23 6:39 UTC (permalink / raw)
To: buildroot
Baruch, All,
On 2018-08-23 06:42 +0300, Baruch Siach spake thusly:
> Yann E. MORIN writes:
> > On 2018-08-23 00:09 +0200, Yann E. MORIN spake thusly:
> >> On 2018-08-23 00:58 +0300, Baruch Siach spake thusly:
> >> > Old version of cmake break cross-compilation when FindThreads is used
> >> > because of a try_run call. Add a workaround that avoids try_run.
> >> >
> >> > cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
> >> >
> >> > Should fix:
> >> > http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
> >> > http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
> >> >
> >> > Cc: Scott Fan <fancp2007@gmail.com>
> >> > Signed-off-by: Baruch Siach <baruch@tkos.co.il>
> >> > ---
> >> > Hi Peter, Yann,
> >> >
> >> > Can one of you test this fix on one of the affected autobuilders?
> >> >
> >> > http://autobuild.buildroot.net/?reason=libssh-0.8.1
[--SNIP--]
> > Here are the results of the configure step, using the config from my
> > autobuilder referenced above, and running 'make libssh-depends' first:
>
> You meant to say 'make libssh-configure' here, right?
No I meant that I ran:
$ make libssh-depends
[...]
$ make libssh-configure
[...]
And I only pasted starting with the second command.
> So I reproduced the build failure and the fix with host-cmake here as
> well.
Thanks for finding the issue and fixing it. :-)
[--SNIP--]
> > CMake Warning:
> > Manually-specified variables were not used by the project:
[--SNIP--]
> > THREADS_PTHREAD_ARG
I find it weird that THREADS_PTHREAD_ARG is reported as unused, when it
is actually it that fixes the issue... :-/
Regards,
Yann E. MORIN.
--
.-----------------.--------------------.------------------.--------------------.
| Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ |
| +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. |
'------------------------------^-------^------------------^--------------------'
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-22 21:58 [Buildroot] [PATCH] libssh: fix cross compile with older cmake Baruch Siach
2018-08-22 22:09 ` Yann E. MORIN
@ 2018-08-23 9:24 ` Jan Kundrát
2018-08-23 9:45 ` Thomas Petazzoni
2018-08-23 9:47 ` Thomas Petazzoni
2018-10-24 11:21 ` Peter Korsgaard
3 siblings, 1 reply; 9+ messages in thread
From: Jan Kundrát @ 2018-08-23 9:24 UTC (permalink / raw)
To: buildroot
On st?eda 22. srpna 2018 23:58:30 CEST, Baruch Siach wrote:
> +# cmake older than 3.10 require this to avoid try_run() in FindThreads
> +LIBSSH_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
Are you sure that this is a correct fix? From reading the
FindThreads.cmake, passing OFF looks like it results in not feeding the
-pthread option to the compiler. That breaks some scenarios such as ASAN,
see [1] for details.
Cheers,
Jan
[1] https://gitlab.kitware.com/cmake/cmake/issues/16609
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-23 9:24 ` Jan Kundrát
@ 2018-08-23 9:45 ` Thomas Petazzoni
0 siblings, 0 replies; 9+ messages in thread
From: Thomas Petazzoni @ 2018-08-23 9:45 UTC (permalink / raw)
To: buildroot
Hello,
On Thu, 23 Aug 2018 11:24:47 +0200, Jan Kundr?t wrote:
> Are you sure that this is a correct fix? From reading the
> FindThreads.cmake, passing OFF looks like it results in not feeding the
> -pthread option to the compiler. That breaks some scenarios such as ASAN,
> see [1] for details.
At least, we are doing it in a number of other packages:
package/exiv2/exiv2.mk:EXIV2_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
package/i2pd/i2pd.mk:I2PD_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
package/librtlsdr/librtlsdr.mk:LIBRTLSDR_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
package/rabbitmq-c/rabbitmq-c.mk:RABBITMQ_C_CONF_OPTS += -DTHREADS_PTHREAD_ARG=OFF
It doesn't mean it's correct, but at least that's how we are working
around this problem at the moment. If it's not the correct way, then we
should fix it globally :-)
Best regards,
Thomas
--
Thomas Petazzoni, CTO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-22 21:58 [Buildroot] [PATCH] libssh: fix cross compile with older cmake Baruch Siach
2018-08-22 22:09 ` Yann E. MORIN
2018-08-23 9:24 ` Jan Kundrát
@ 2018-08-23 9:47 ` Thomas Petazzoni
2018-10-24 11:21 ` Peter Korsgaard
3 siblings, 0 replies; 9+ messages in thread
From: Thomas Petazzoni @ 2018-08-23 9:47 UTC (permalink / raw)
To: buildroot
Hello Baruch,
On Thu, 23 Aug 2018 00:58:30 +0300, Baruch Siach wrote:
> Old version of cmake break cross-compilation when FindThreads is used
> because of a try_run call. Add a workaround that avoids try_run.
>
> cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
>
> Should fix:
> http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
> http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
>
> Cc: Scott Fan <fancp2007@gmail.com>
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
It wasn't clear from your commit log if this patch was for next or
master. However, the build issue only happened on next for now, and
is probably related to the libssh version bump that we have in next, so
I applied your patch to the next branch.
Thanks,
Thomas
--
Thomas Petazzoni, CTO, Bootlin (formerly Free Electrons)
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 9+ messages in thread
* [Buildroot] [PATCH] libssh: fix cross compile with older cmake
2018-08-22 21:58 [Buildroot] [PATCH] libssh: fix cross compile with older cmake Baruch Siach
` (2 preceding siblings ...)
2018-08-23 9:47 ` Thomas Petazzoni
@ 2018-10-24 11:21 ` Peter Korsgaard
3 siblings, 0 replies; 9+ messages in thread
From: Peter Korsgaard @ 2018-10-24 11:21 UTC (permalink / raw)
To: buildroot
>>>>> "Baruch" == Baruch Siach <baruch@tkos.co.il> writes:
> Old version of cmake break cross-compilation when FindThreads is used
> because of a try_run call. Add a workaround that avoids try_run.
> cmake bug report: https://gitlab.kitware.com/cmake/cmake/issues/16920
> Should fix:
> http://autobuild.buildroot.net/results/8aa/8aa2bd894416a4508ca7140f8947ff46243f8b78/
> http://autobuild.buildroot.net/results/f2c/f2cc965bb134bf4fd9e625eb267b67c949c202fc/
> Cc: Scott Fan <fancp2007@gmail.com>
> Signed-off-by: Baruch Siach <baruch@tkos.co.il>
Committed to 2018.02.x and 2018.08.x, thanks.
--
Bye, Peter Korsgaard
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2018-10-24 11:21 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-08-22 21:58 [Buildroot] [PATCH] libssh: fix cross compile with older cmake Baruch Siach
2018-08-22 22:09 ` Yann E. MORIN
2018-08-22 22:27 ` Yann E. MORIN
2018-08-23 3:42 ` Baruch Siach
2018-08-23 6:39 ` Yann E. MORIN
2018-08-23 9:24 ` Jan Kundrát
2018-08-23 9:45 ` Thomas Petazzoni
2018-08-23 9:47 ` Thomas Petazzoni
2018-10-24 11:21 ` Peter Korsgaard
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox