[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Chicken-hackers] [PATCH] Fix #1133
From: |
Aleksej Saushev |
Subject: |
Re: [Chicken-hackers] [PATCH] Fix #1133 |
Date: |
Thu, 03 Jul 2014 22:23:24 +0400 |
User-agent: |
Gnus/5.1299999999999999 (Gnus v5.13) Emacs/24.3 (berkeley-unix) |
Yaroslav Tsarko <address@hidden> writes:
> Sure. First, please take a look at the following CMake wiki
> page: http://www.cmake.org/Wiki/CMake_Cross_Compiling.
>
> In addition to that many CMake commands already know how to
> properly work in cross-compilation mode (for example:
> find_library command
> http://www.cmake.org/cmake/help/v2.8.12/cmake.html#command:find_library).
>
> In common scenario all you need to do is to set up a few CMake
> variables to specify your cross-compilation target and CMake
> will handle many things automatically.
>
> As example (I used this to build CLucene library on my Ubuntu
> 12.04 system for Windows):
>
> cmake -D CMAKE_TOOLCHAIN_FILE=mingw-w64-toolchain.cmake -D
> CMAKE_INSTALL_PREFIX=<path> ..
>
> where mentioned mingw-w64-toolchain.cmake file contains:
>
> SET(CMAKE_SYSTEM_NAME Windows)
> SET(GNU_HOST i686-w64-mingw32)
> SET(CMAKE_C_COMPILER i686-w64-mingw32-gcc)
> SET(CMAKE_CXX_COMPILER i686-w64-mingw32-g++)
> SET(CMAKE_RC_COMPILER i686-w64-mingw32-windres)
> SET(CMAKE_FIND_ROOT_PATH <path-to-mingw32> )
This is exactly the demonstration why CMake's support for cross-compilation
is no better than Make's. The analogous code for Make is:
make CC=i686-w64-mingw32-gcc CXX=i686-w64-mingw32-g++ SYSROOT=<path-to-mingw32>
The most important part here is that you have to add it manually while autoconf
has almost all the useful stuff already inside.
In general, CMake doesn't solve any real problem of Make. In some aspects
it is a step back even. CMake is mostly equivalent to Make + some autotools.
The only Make's problem it does solve is the problem of divergent dialects.
CMake has only one. But that's triviality. We employ the same solution
by requiring bmake and ignoring all other dialects.
Otherwise CMake is "yet another tool" that requires additional maintainance.
--
HE CE3OH...
- Re: [Chicken-hackers] [PATCH] Fix #1133, (continued)
- Re: [Chicken-hackers] [PATCH] Fix #1133, Evan Hanson, 2014/07/01
- Re: [Chicken-hackers] [PATCH] Fix #1133, Oleg Kolosov, 2014/07/02
- Re: [Chicken-hackers] [PATCH] Fix #1133, Oleg Kolosov, 2014/07/02
- Re: [Chicken-hackers] [PATCH] Fix #1133, Aleksej Saushev, 2014/07/03
- Re: [Chicken-hackers] [PATCH] Fix #1133, Yaroslav Tsarko, 2014/07/03
- Re: [Chicken-hackers] [PATCH] Fix #1133, Felix Winkelmann, 2014/07/03
- Re: [Chicken-hackers] [PATCH] Fix #1133, Yaroslav Tsarko, 2014/07/03
- Re: [Chicken-hackers] [PATCH] Fix #1133, Felix Winkelmann, 2014/07/03
- Re: [Chicken-hackers] [PATCH] Fix #1133,
Aleksej Saushev <=
- Re: [Chicken-hackers] [PATCH] Fix #1133, Jörg F. Wittenberger, 2014/07/04
- Re: [Chicken-hackers] [PATCH] Fix #1133, Aleksej Saushev, 2014/07/03
Re: [Chicken-hackers] [PATCH] Fix #1133, Arthur Maciel, 2014/07/06
Re: [Chicken-hackers] [PATCH] Fix #1133, Arthur Maciel, 2014/07/06