SIPp / sipp

The SIPp testing tool
https://sipp.readthedocs.io
Other
921 stars 383 forks source link

cmake . * failing #597

Closed enneig closed 1 year ago

enneig commented 1 year ago

Hello,

Building the projects fails, I use the following snippet for compiling:

git clone https://github.com/SIPp/sipp.git
cd sipp 
cmake . -DUSE_GSL=1 -DUSE_PCAP=1 -DUSE_SSL=1 -DUSE_SCTP=1

which gives the following output:

-- The C compiler identification is GNU 11.3.0
-- The CXX compiler identification is GNU 11.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Looking for sys/endian.h
-- Looking for sys/endian.h - not found
-- Looking for sys/epoll.h
-- Looking for sys/epoll.h - found
-- Performing Test HAVE_UDP_UH_PREFIX
-- Performing Test HAVE_UDP_UH_PREFIX - Success
-- Looking for le16toh
-- Looking for le16toh - found
-- Looking for le16toh
-- Looking for le16toh - not found
-- Checking for one of the modules 'openssl>=0.9.8;wolfssl>=3.15.0'
-- Found Git: /usr/bin/git (found version "2.34.1") 
-- Checking for one of the modules 'ncursesw;cursesw;ncurses;curses'
-- Checking for one of the modules 'tinfo'
-- Configuring done
CMake Error at CMakeLists.txt:122 (add_executable):
  Cannot find source file:

    /sipp/gtest/googletest/src/gtest-all.cc

  Tried extensions .c .C .c++ .cc .cpp .cxx .cu .mpp .m .M .mm .ixx .cppm .h
  .hh .h++ .hm .hpp .hxx .in .txx .f .F .for .f77 .f90 .f95 .f03 .hip .ispc

CMake Error at CMakeLists.txt:122 (add_executable):
  No SOURCES given to target: sipp_unittest

CMake Generate step failed.  Build files cannot be regenerated correctly.

the build.sh script gives the same error.

I think it has something to do with this commit (https://github.com/SIPp/sipp/commit/33aef90f6a1b7cc2ea73f7eb1497c7c592026671) from 25-nov

Regards Rene

enneig commented 1 year ago

Hello,

for anyone with a similar issue here is a workaround

using this git clone instead of the one in the example: git clone --recurse-submodules https://github.com/SIPp/sipp.git this will download the dependant git repo as well.

Regards Rene

p120ph37 commented 1 year ago

Yes, you can use that as your initial clone command, or if you already have a clone of the repo, you can initialize the git submodules inside your existing clone by using this command: https://github.com/SIPp/sipp/blob/1dfca1f166c2f9168764a95b4255b2f5b9defc8d/.github/workflows/ccpp.yml#L24

enneig commented 1 year ago

Closing issue, above snippet works again as of v3.7.1

Thanks