pfultz2/cget

Automatically generated CMakeLists.txt ends in error for --cmake autotools

Closed this issue · 3 comments

I am currently using cget 0.1.7 and cmake 3.5.1 on ubuntu 16.04 lts

I have tried to install libffi v3.2.1 via requirements.txt file, with the following line
libffi,libffi/libffi@v3.2.1 --cmake autotools, but the automatically generated CMakeLists.txt ends execution with the error shown below. Using the command cget install libffi,libffi/libffi@v3.2.1 --cmake autotools results in the same error.

Downloading https://github.com/libffi/libffi/archive/v3.2.1.tar.gz
  [######################################################################]  100%
Extracting archive /home/igor/foo/cget/cget/build/tmp-98ba454730bf43a3bc7acf6ed231570e/v3.2.1.tar.gz ...
-- The C compiler identification is GNU 5.4.0
-- The CXX compiler identification is GNU 5.4.0
-- Check for working C compiler using: Ninja
-- Check for working C compiler using: Ninja -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler using: Ninja
-- Check for working CXX compiler using: Ninja -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
No such file or directory
CMake Error at CMakeLists.txt:33 (message):
  Process failed:
  COMMAND;/usr/bin/cmake;-E;env;PATH=/home/igor/foo/cget/bin:/usr/local/bin:/usr/bin://bin:/usr/bin:/home/igor/foo/cget/cget/pkg/libffi/install/bin:/home/igor/foo/cget/bin:/toolchain/mips-4.3-51/mips-4.3/bin:/toolchain/arm-2014.05/bin:/usr/lib/ccache:/home/igor/bin:/usr/local/bin:/toolchain/mips-4.3-51/mips-4.3/bin:/toolchain/arm-2014.05/bin:/usr/lib/ccache:/home/igor/bin:/usr/local/bin:/home/igor/.cargo/bin:/home/igor/.cargo/bin:/home/igor/bin:/home/igor/.local/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/lib/jvm/java-8-oracle/bin:/usr/lib/jvm/java-8-oracle/db/bin:/usr/lib/jvm/java-8-oracle/jre/bin;PKG_CONFIG_PATH=/home/igor/foo/cget/lib/pkgconfig:/home/igor/foo/cget/lib64/pkgconfig:/home/igor/foo/cget/share/pkgconfig:/usr/local/lib/pkgconfig:/usr/local/lib64/pkgconfig:/usr/local/share/pkgconfig:/usr/lib/pkgconfig:/usr/lib64/pkgconfig:/usr/share/pkgconfig://lib/pkgconfig://lib64/pkgconfig://share/pkgconfig:/usr/lib/pkgconfig:/usr/lib64/pkgconfig:/usr/share/pkgconfig:/home/igor/foo/cget/cget/pkg/libffi/install/lib/pkgconfig:/home/igor/foo/cget/cget/pkg/libffi/install/lib64/pkgconfig:/home/igor/foo/cget/cget/pkg/libffi/install/share/pkgconfig;CC=/usr/lib/ccache/cc;CXX=/usr/lib/ccache/c++;CFLAGS=-isystem
  /home/igor/foo/cget/include -isystem
  /home/igor/foo/cget/include;CXXFLAGS=-isystem
  /home/igor/foo/cget/include -isystem
  /home/igor/foo/cget/include;LDFLAGS=;/home/igor/foo/cget/cget/build/tmp-98ba454730bf43a3bc7acf6ed231570e/libffi-3.2.1/configure;--prefix=/home/igor/foo/cget/cget/pkg/libffi/install;WORKING_DIRECTORY;/home/igor/foo/cget/cget/build/tmp-98ba454730bf43a3bc7acf6ed231570e/build/build
Call Stack (most recent call first):
  CMakeLists.txt:147 (exec)


-- Configuring incomplete, errors occurred!
See also "/home/igor/foo/cget/cget/build/tmp-98ba454730bf43a3bc7acf6ed231570e/build/CMakeFiles/CMakeOutput.log".
Command failed: ['/usr/bin/cmake', '-DCMAKE_TOOLCHAIN_FILE=/home/igor/foo/cget/cget/cget.cmake', '-G', u'Ninja', '/home/igor/foo/cget/cget/build/tmp-98ba454730bf43a3bc7acf6ed231570e/libffi-3.2.1', '-DCGET_CMAKE_DIR=/usr/local/lib/python2.7/dist-packages/cget/cmake', '-DCGET_CMAKE_ORIGINAL_SOURCE_FILE=/home/igor/foo/cget/cget/build/tmp-98ba454730bf43a3bc7acf6ed231570e/libffi-3.2.1/__cget_original_cmake_file__.cmake', '-DBUILD_TESTING=Off', '-DCMAKE_BUILD_TYPE=Release', '-DCMAKE_INSTALL_PREFIX=/home/igor/foo/cget/cget/pkg/libffi/install']
Failed to build package libffi```

The libffi directly from github does not provide the top-level configure script. It is available if you download it from their ftp site, or from github from the release assets like for 3.3 here.

There is a configure.ac file which can be used to generate the configure script. It should probably try to generate it if the configure script is missing.

Thanks! It was really helpful. Problem solved!