I could not find the case of definition of HAVE_PTHREAD without the src directory after "cmake .." and "cmake .".
The sets are the blow:
---
CmakeLists.txt:
cmake_minimum_required(VERSION 2.8.12.2)
project(lib_a)
#add_executable(Tutorial main.c)
#configure_file(TutorialConfig.h.in TutorialConfig.h)
#configure_file(array_counter.h.in array_counter.h)
set(wxSOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR})
set(wxBINARY_DIR ${CMAKE_BINARY_DIR})
set(wxOUTPUT_DIR ${wxBINARY_DIR}/lib)
---
$ tree
.
├── CMakeLists.txt
├── build
├── lib
└── src
├── main.c
└── main.h
3 directories, 3 files
---
$ cmake ..
-- The C compiler identification is GNU 4.4.7
-- The CXX compiler identification is GNU 4.4.7
-- Check for working C compiler: /usr/bin/cc
-- Check for working C compiler: /usr/bin/cc -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Configuring done
-- Generating done
-- Build files have been written to: /home/nakagawa/src/20200924/build
---
.
├── CMakeLists.txt
├── build
│ ├── CMakeCache.txt
│ ├── CMakeFiles
│ │ ├── 2.8.12.2
│ │ │ ├── CMakeCCompiler.cmake
│ │ │ ├── CMakeCXXCompiler.cmake
│ │ │ ├── CMakeDetermineCompilerABI_C.bin
│ │ │ ├── CMakeDetermineCompilerABI_CXX.bin
│ │ │ ├── CMakeSystem.cmake
│ │ │ ├── CompilerIdC
│ │ │ │ ├── CMakeCCompilerId.c
│ │ │ │ └── a.out
│ │ │ └── CompilerIdCXX
│ │ │ ├── CMakeCXXCompilerId.cpp
│ │ │ └── a.out
│ │ ├── CMakeDirectoryInformation.cmake
│ │ ├── CMakeOutput.log
│ │ ├── CMakeTmp
│ │ ├── Makefile.cmake
│ │ ├── Makefile2
│ │ ├── TargetDirectories.txt
│ │ ├── cmake.check_cache
│ │ └── progress.marks
│ ├── Makefile
│ └── cmake_install.cmake
├── lib
└── src
├── main.c
└── main.h
8 directories, 22 files
---
$ grep -R . |grep PTHREAD
src/main.h:#define HAVE_PTHREAD 1
We could yum-search cmake-gui, install it and boot it so that easily create project files for compilation, which means almost make files as configured: cmake-gui can use VERSION 3.6.1 if you add entry: message is the below: CMake Error: The source directory "...../read_005/src" does not appear to contain CMakeLists.txt. Specify --help for usage, or press the help button on the CMake GUI. We must create CMakeLists.txt but we can select "from UNIX makefile" as "Configure". "cmake-gui" itself is CMake 2.8.12.2 displayed. We could see CmakeCache.txt like the below so that we could not create tags by use of cmak-gui. ######################## # EXTERNAL cache entries ######################## cmake_minimum_required:STRING=VERSION 3.6.1 We'd rather love: cmake_minimum_required(VERSION 3.6.1) cmake-gui version itself must be higher, at least, we think. (20200911: cmake3-gui) Configured and Generator: Now they are same. --- CMake Error: The source dir...
Comments
Post a Comment