29,371 questions
1
vote
1
answer
4k
views
Cmake's undefined reference linking error
I am customizing qgis source code that builds through cmake.
It has a source tree with many sub directories(with sub-directories withinin them aswell).
The whole source tree is divided into modules ...
3
votes
5
answers
11k
views
Regular expression for hidden files under unix
I'm looking for a regex to match every file begining with a "." in a directory.
I'm using CMake (from CMake doc : "CMake expects regular expressions, not globs") and want to ignore every file ...
86
votes
7
answers
135k
views
How to copy directory from source tree to binary tree?
Copying directory from source tree to binary tree. For example: How to copy www to bin folder.
work
├─bin
└─src
├─doing
│ └─www
├─include
└─lib
Thanks.
23
votes
2
answers
24k
views
CMake : how to use bash command in CMakeLists.txt
I'm wondering how I can use bash command in CMakeLists.txt. What I want is to get the number of processor retrieved using :
export variable=`getconf _NPROCESSORS_ONLN`
and set NB_PROCESSOR to ...
5
votes
3
answers
13k
views
How to automatically generate C header file using CMake?
I'm looking for a way to automatically generate a header file. This file is the public interface of a library and i want to "fill" some structures and stuff before compilation.
For example, in the ...
27
votes
1
answer
18k
views
How do I fix an apparently corrupted CMake build?
I am getting the following error from CMakeSetup on our source tree:
CMake Error: Error required internal CMake variable not set, cmake may be not be built correctly.
Missing variable is:
...
30
votes
9
answers
26k
views
cmake RUNTIME_OUTPUT_DIRECTORY on Windows
I'm using cmake for managing my cross-platform builds, and I have everything worked out except for this problem. I set RUNTIME_OUTPUT_DIRECTORY to a bin/ directory where I have data files stored. On ...
7
votes
4
answers
5k
views
Any way in CMake to require GCC version 4+?
I am using some features that are provided in GCC v4+ and would like CMake to find GCC v4 compiler and if it does not find it, return an error stating GCC v4 is required.
Anyone have any modules / ...
19
votes
1
answer
21k
views
Call cmake from make to create Makefiles?
I am using cmake to build my project. For UNIX, I would like to type make from my project's root directory, and have cmake invoked to create the proper Makefiles (if they don't exist yet) and then ...
-1
votes
6
answers
2k
views
QAbstractTableModel inheritance vtable problem
Here's another problem with qt:
I extend a QAbstractTableModel, but I get a compiling error ( I'm using cmake)
// file.h
#ifndef TABLEMODEL_H
#define TABLEMODEL_H
#include <QAbstractTableModel>...
125
votes
12
answers
107k
views
Using pre-compiled headers with CMake
I have seen a few (old) posts on the 'net about hacking together some support for pre-compiled headers in CMake. They all seem a bit all-over the place and everyone has their own way of doing it. What ...