Configure Error:Unknown CMake command "fc_wrap_cpp".

Having trouble installing or compiling FreeCAD? Get help here.
UR_
Posts: 1020
Joined: Tue Jan 03, 2017 8:42 pm

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby UR_ » Tue May 07, 2019 8:41 am

apeltauer wrote:
Tue May 07, 2019 7:30 am
i would say, give it a try....
I gave it a try, but no luck :(

Started cmake 3.14.3 with this .bat

Code: Select all

set FREECAD_LIBPACK_DIR=C:\Users\aio\FreeCADlibpack
set path=C:\Users\aio\FreeCADcode;C:\Users\aio\FreeCADbuild;C:\Users\aio\FreeCADlibpack;


"C:\Program Files\CMake\bin\cmake-gui.exe" ^
      -G "Visual Studio 15 2017 Win64" ^
      -DCMAKE_INSTALL_PREFIX=C:\Users\aio\FreeCADbuild ^
      -DFREECAD_LIBPACK_USE=TRUE

pause

and got this:

Code: Select all

CMake Error at C:/Program Files/CMake/share/cmake-3.14/Modules/FindBoost.cmake:2147 (message):
  Unable to find the requested Boost libraries.

  Boost version: 1.67.0

  Boost include path: C:/Users/aio/FreeCADlibpack/include

  Could not find the following Boost libraries:

          boost_filesystem
          boost_program_options
          boost_regex
          boost_system
          boost_thread

  Some (but not all) of the required Boost libraries were found.  You may
  need to install these additional Boost libraries.  Alternatively, set
  BOOST_LIBRARYDIR to the directory containing Boost libraries or BOOST_ROOT
  to the location of Boost.
Call Stack (most recent call first):
  CMakeLists.txt:613 (find_package)


CMake Error at CMakeLists.txt:629 (MESSAGE):
  =============================================

  Required components:

   filesystem;program_options;regex;system;thread

  Not found, install the components:

   filesystem;program_options;regex;system;thread

  =============================================
tak
Posts: 22
Joined: Thu May 02, 2019 2:32 am

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby tak » Tue May 07, 2019 8:49 am

apeltauer wrote:
Tue May 07, 2019 7:30 am
i would say, give it a try.... :)
  • clone the freecad git repo
  • create a folder for your build, e.g. "bin" next to your freecad repository
  • create a folder for the libpack, e.g. "FreeCADLibs_11.5.3_x64_VC12" next to your freecad repository
  • create a environment variable "FREECAD_LIBPACK_DIR" and select the path to the libpack (i usually set the variable in cmd with set.... )
  • run cmake, select your repository as source code and your bin folder as "where to build the binaries"
  • click configure, select your compiler and make sure you select the x64 version!
  • cmake should find all dependencies from the libpack
I download FreeCADLibs_12.1.2_x64_VC15 and put the files to my 0.18 source. But there is a error. the boost file cannot found. But there are the files in the include/boost folder
https://imgur.com/P7jPgGW
https://imgur.com/JBBIpmF
wmayer
Site Admin
Posts: 15001
Joined: Thu Feb 19, 2009 10:32 am

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby wmayer » Tue May 07, 2019 8:56 am

Look at the output of CMake. The path to the OCE/Opencascade header files is not correct.
User avatar
apeltauer
Posts: 212
Joined: Fri Aug 11, 2017 2:19 pm

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby apeltauer » Tue May 07, 2019 8:57 am

Can you try to set the env varibale inside cmd and then start the cmke gui. And then set the source code dir and the bin dir. Then click configure....
It is just a try to configure all by hand and not by a script...
BTW: Cmake writes the following if the libpack was found: Found libpack env variable: ******/FreeCADLibs_12.1.2_x64_VC15
User avatar
apeltauer
Posts: 212
Joined: Fri Aug 11, 2017 2:19 pm

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby apeltauer » Tue May 07, 2019 9:09 am

Another thing, if you use the cmake gui, please delete your cmake cache with "File-->Delete Cache" when trying to set some variables again in cmake.
Some times the variables are cached and not over written.... Then it is getting messy to find the error... :)
tak
Posts: 22
Joined: Thu May 02, 2019 2:32 am

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby tak » Wed May 08, 2019 2:50 am

wmayer wrote:
Tue May 07, 2019 8:56 am
Look at the output of CMake. The path to the OCE/Opencascade header files is not correct.
There is not Opencascade_DIR entry. I added this. It is disappear after configure.
tak
Posts: 22
Joined: Thu May 02, 2019 2:32 am

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby tak » Wed May 08, 2019 2:51 am

apeltauer wrote:
Tue May 07, 2019 8:57 am
Can you try to set the env varibale inside cmd and then start the cmke gui. And then set the source code dir and the bin dir. Then click configure....
It is just a try to configure all by hand and not by a script...
BTW: Cmake writes the following if the libpack was found: Found libpack env variable: ******/FreeCADLibs_12.1.2_x64_VC15
how can I set the env varibale inside cmd ?
User avatar
apeltauer
Posts: 212
Joined: Fri Aug 11, 2017 2:19 pm

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby apeltauer » Wed May 08, 2019 5:15 am

start a command promt and enter "set my_new_varibale=c:\temp" then check your varibale with "set my"....
tak
Posts: 22
Joined: Thu May 02, 2019 2:32 am

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby tak » Thu May 09, 2019 5:51 am

I got another problem now.
When check for medfile (libmed and libmedc), there is a error 'Unknown CMake command "ctest_empty_binary_directory".'
I checked the config in MEDFILE. "MEDFILE_F_LIBRARIES" not found and "MEDFILE_ROOT_DIR" is nothing. Are there something wrong?
https://imgur.com/r8ayh6E
User avatar
apeltauer
Posts: 212
Joined: Fri Aug 11, 2017 2:19 pm

Re: Configure Error:Unknown CMake command "fc_wrap_cpp".

Postby apeltauer » Thu May 09, 2019 6:34 am

tak wrote:
Thu May 09, 2019 5:51 am
I got another problem now.
When check for medfile (libmed and libmedc), there is a error 'Unknown CMake command "ctest_empty_binary_directory".'
I checked the config in MEDFILE. "MEDFILE_F_LIBRARIES" not found and "MEDFILE_ROOT_DIR" is nothing. Are there something wrong?
https://imgur.com/r8ayh6E
In your pic i can see that your are using the libpack version 11.11. Any reason why not switching to the new one, version 12.1.2?