build-process
Building a library using autotools from cmake
I think that you’d be better off using the ExternalProject feature of cmake. I guess you have your project and have libantrl in a sub directory? project +- libantlr +- mysrc —- etc —- If that’s the case, you can do something like this in the top level CMakeLists.txt: cmake_minimum_required(VERSION 2.8) project(test) include(ExternalProject) ExternalProject_Add(libantlr SOURCE_DIR … Read more
What is currently the best build system [closed]
I’d definitively put my vote up for premake. Although it is not as powerful as it’s older brothers, it’s main advantage is absurd simplicity and ease of use. Makes writing multi-compiler, multi-platform code a breeze, and natively generates Visual Studio solutions, XCode projects, Makefiles, and others, without any additional work needed.
What is your experience with non-recursive make? [closed]
We use a non-recursive GNU Make system in the company I work for. It’s based on Miller’s paper and especially the “Implementing non-recursive make” link you gave. We’ve managed to refine Bergen’s code into a system where there’s no boiler plate at all in subdirectory makefiles. By and large, it works fine, and is much … Read more
ld linker question: the –whole-archive option
There are legitimate uses of –whole-archive when linking executable with static libraries. One example is building C++ code, where global instances “register” themselves in their constructors (warning: untested code): handlers.h typedef void (*handler)(const char *data); void register_handler(const char *protocol, handler h); handler get_handler(const char *protocol); handlers.cc (part of libhandlers.a) typedef map<const char*, handler> HandlerMap; HandlerMap … Read more