Mike There are two common problems for the cmake procedure failing. The first is the relative addressing to the source locations from the build directory. That usually results in the Cmake execution failing early but if cmake finds CMakelists.txt file in the directory that it will start to build with the information that is in that file. The gnucash-4.<x> directory has sub directories which contain Cmakelists.txt files which are usually copied to the build directory not executed directly.
If you are following the instructions given in the Wiki page ( https://wiki.gnucash.org/wiki/Building_On_Linux and your directory structure looks like parent | --------------------- | | gnucash-4.<x> build-gnucash-4.<x> the " ../gnucash-4.<x>" as the last part of the cmake command should be addressing the correct directory. You can also specifiy an absolute address with the full path from the root directory to the source files i.e. "/home/<user>/ .../gnucash-4.<x>" if you are not confident with the relative addressing. Problems usually arise when the source directory and the build directory are not in the above configuration and the relative address in the cmake command does not address the top level directory of the sources correctly (I personally build in a different configuration so I use a different relative addressing from that given in the wiki). The cmake procedure first checks for the presence of the dependency libraries, particularly the development headers for those libraries, before starting the build itself. If a dependency is missing it will usually list it and then stop and not attempt to build the libraries. I don't know if that output is normally reflected to the error log. The output to the terminal during the build will usually list those checks. I suspect your problem is associated with an incorrect relative addressing of the sources but can't be sure. If you could copy the terminal output produced when you run cmake to a text file (the terminal uses Shift-Ctrl-C to copy by default not Ctrl-C, open the text editor copy it in and save) and attach it as well as the error log file we may get a better idea. If you can also include the exact cmake command you used to initiate the procedure that may also help with working out what is happening. I build fairly infrequently these days and don't normally have any problems so I am no longer as familiar with the output as I was when I last reworked the Wiki pages a few years ago. David Cousens On Wed, 2021-05-19 at 15:52 -0500, mike823 wrote: > Thank you John, > > How do I get support for build? I've sent two days ago a message to "GnuCash > - Dev" but no answer. > > Here is the error I am getting: > > > [******@CentOS-8dot1 gnucash-build]$ cat > /home/******/gnucash-build/CMakeFiles/CMakeError.log > Determining if the pthread_create exist failed with the following output: > Change Dir: /home/******/gnucash-build/CMakeFiles/CMakeTmp > > Run Build Command:"/usr/bin/gmake" "cmTC_8837a/fast" > /usr/bin/gmake -f CMakeFiles/cmTC_8837a.dir/build.make > CMakeFiles/cmTC_8837a.dir/build > gmake[1]: Entering directory > '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > Building C object CMakeFiles/cmTC_8837a.dir/CheckSymbolExists.c.o > /usr/bin/cc -o CMakeFiles/cmTC_8837a.dir/CheckSymbolExists.c.o -c > /home/******/gnucash-build/CMakeFiles/CMakeTmp/CheckSymbolExists.c > Linking C executable cmTC_8837a > /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_8837a.dir/link.txt > --verbose=1 > /usr/bin/cc CMakeFiles/cmTC_8837a.dir/CheckSymbolExists.c.o -o > cmTC_8837a > CMakeFiles/cmTC_8837a.dir/CheckSymbolExists.c.o: In function `main': > CheckSymbolExists.c:(.text+0x16): undefined reference to `pthread_create' > collect2: error: ld returned 1 exit status > gmake[1]: *** [CMakeFiles/cmTC_8837a.dir/build.make:87: cmTC_8837a] Error 1 > gmake[1]: Leaving directory '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > gmake: *** [Makefile:126: cmTC_8837a/fast] Error 2 > > File /home/******/gnucash-build/CMakeFiles/CMakeTmp/CheckSymbolExists.c: > /* */ > #include <pthread.h> > > int main(int argc, char** argv) > { > (void)argv; > #ifndef pthread_create > return ((int*)(&pthread_create))[argc]; > #else > (void)argc; > return 0; > #endif > } > > Determining if the function pthread_create exists in the pthreads failed > with the following output: > Change Dir: /home/******/gnucash-build/CMakeFiles/CMakeTmp > > Run Build Command:"/usr/bin/gmake" "cmTC_fead3/fast" > /usr/bin/gmake -f CMakeFiles/cmTC_fead3.dir/build.make > CMakeFiles/cmTC_fead3.dir/build > gmake[1]: Entering directory > '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > Building C object CMakeFiles/cmTC_fead3.dir/CheckFunctionExists.c.o > /usr/bin/cc -DCHECK_FUNCTION_EXISTS=pthread_create -o > CMakeFiles/cmTC_fead3.dir/CheckFunctionExists.c.o -c > /usr/share/cmake/Modules/CheckFunctionExists.c > Linking C executable cmTC_fead3 > /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_fead3.dir/link.txt > --verbose=1 > /usr/bin/cc -DCHECK_FUNCTION_EXISTS=pthread_create > CMakeFiles/cmTC_fead3.dir/CheckFunctionExists.c.o -o cmTC_fead3 -lpthreads > /usr/bin/ld: cannot find -lpthreads > collect2: error: ld returned 1 exit status > gmake[1]: *** [CMakeFiles/cmTC_fead3.dir/build.make:87: cmTC_fead3] Error 1 > gmake[1]: Leaving directory '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > gmake: *** [Makefile:126: cmTC_fead3/fast] Error 2 > > > Determining if the AB_Banking_RuntimeConfig_SetCharValue exist failed with > the following output: > Change Dir: /home/******/gnucash-build/CMakeFiles/CMakeTmp > > Run Build Command:"/usr/bin/gmake" "cmTC_0b53b/fast" > /usr/bin/gmake -f CMakeFiles/cmTC_0b53b.dir/build.make > CMakeFiles/cmTC_0b53b.dir/build > gmake[1]: Entering directory > '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > Building C object CMakeFiles/cmTC_0b53b.dir/CheckSymbolExists.c.o > /usr/bin/cc -I/usr/include/aqbanking6 -I/usr/include/gwenhywfar5 -o > CMakeFiles/cmTC_0b53b.dir/CheckSymbolExists.c.o -c > /home/******/gnucash-build/CMakeFiles/CMakeTmp/CheckSymbolExists.c > Linking C executable cmTC_0b53b > /usr/bin/cmake -E cmake_link_script CMakeFiles/cmTC_0b53b.dir/link.txt > --verbose=1 > /usr/bin/cc CMakeFiles/cmTC_0b53b.dir/CheckSymbolExists.c.o -o > cmTC_0b53b > CMakeFiles/cmTC_0b53b.dir/CheckSymbolExists.c.o: In function `main': > CheckSymbolExists.c:(.text+0x16): undefined reference to > `AB_Banking_RuntimeConfig_SetCharValue' > collect2: error: ld returned 1 exit status > gmake[1]: *** [CMakeFiles/cmTC_0b53b.dir/build.make:87: cmTC_0b53b] Error 1 > gmake[1]: Leaving directory '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > gmake: *** [Makefile:126: cmTC_0b53b/fast] Error 2 > > File /home/******/gnucash-build/CMakeFiles/CMakeTmp/CheckSymbolExists.c: > /* */ > #include <aqbanking/banking.h> > > int main(int argc, char** argv) > { > (void)argv; > #ifndef AB_Banking_RuntimeConfig_SetCharValue > return ((int*)(&AB_Banking_RuntimeConfig_SetCharValue))[argc]; > #else > (void)argc; > return 0; > #endif > } > > Determining if compiler accepts -pthread failed with the following output: > Change Dir: /home/******/gnucash-build/CMakeFiles/CMakeTmp > > Run Build Command:"/usr/bin/gmake" "cmTC_45026/fast" > /usr/bin/gmake -f CMakeFiles/cmTC_45026.dir/build.make > CMakeFiles/cmTC_45026.dir/build > gmake[1]: Entering directory > '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > Building C object CMakeFiles/cmTC_45026.dir/CheckForPthreads.c.o > /usr/bin/cc -Wno-error=deprecated-declarations -Wno-error=parentheses > -Werror -Wdeclaration-after-statement -Wno-pointer-sign -Wall > -Wmissing-prototypes -Wmissing-declarations -Wno-unused -std=gnu11 -o > CMakeFiles/cmTC_45026.dir/CheckForPthreads.c.o -c > /usr/share/cmake/Modules/CheckForPthreads.c > /usr/share/cmake/Modules/CheckForPthreads.c:3:7: error: no previous > prototype for ‘start_routine’ [-Werror=missing-prototypes] > void* start_routine(void* args) > ^~~~~~~~~~~~~ > cc1: all warnings being treated as errors > gmake[1]: *** [CMakeFiles/cmTC_45026.dir/build.make:66: > CMakeFiles/cmTC_45026.dir/CheckForPthreads.c.o] Error 1 > gmake[1]: Leaving directory '/home/******/gnucash-build/CMakeFiles/CMakeTmp' > gmake: *** [Makefile:126: cmTC_45026/fast] Error 2 > > > [******@CentOS-8dot1 gnucash-build]$ > > > > > -- > Sent from: http://gnucash.1415818.n4.nabble.com/GnuCash-User-f1415819.html > _______________________________________________ > gnucash-user mailing list > [email protected] > To update your subscription preferences or to unsubscribe: > https://lists.gnucash.org/mailman/listinfo/gnucash-user > If you are using Nabble or Gmane, please see > https://wiki.gnucash.org/wiki/Mailing_Lists for more information. > ----- > Please remember to CC this list on all your replies. > You can do this by using Reply-To-List or Reply-All. _______________________________________________ gnucash-user mailing list [email protected] To update your subscription preferences or to unsubscribe: https://lists.gnucash.org/mailman/listinfo/gnucash-user If you are using Nabble or Gmane, please see https://wiki.gnucash.org/wiki/Mailing_Lists for more information. ----- Please remember to CC this list on all your replies. You can do this by using Reply-To-List or Reply-All.
