CMB-BNU / PloidyFrost

reference-free estimation of ploidy level from whole genome sequencing data based on de Bruijn graph
16 stars 2 forks source link

Issue with PloidyFrost compilation #3

Open AndriiTarieiev opened 1 year ago

AndriiTarieiev commented 1 year ago

Dear developers, I tried to compile PloidyFrost on a couple of different systems but it always returns the following error:

-- The C compiler identification is GNU -- The CXX compiler identification is GNU -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done CMake Error at CMakeLists.txt:86 (find_library): Could not find pthread using the following names:

-- Configuring incomplete, errors occurred! See also "СMakeOutput.log".

I would appreciate it if you are able to suggest any solution.

JanneM commented 1 year ago

Hi Andrii,

I solved this for us and I've given the devels a proposed solution. Newer versions of CMake aren't able to use the older CMakeLists file. You can edit it to make it more up to date.

Very briefly, you need to replace the last four lines of "CMakeLists.txt" in the top directory with the following ones (only three of the four have changed):

find_package(Threads) find_package(ZLIB)

add_executable(PloidyFrost ${SOURCES})

target_link_libraries(PloidyFrost ${CMAKE_THREAD_LIBS_INIT} z bifrost kmc )

rachelss commented 1 year ago

Thank you for sharing this solution!

AndriiTarieiev commented 1 year ago

Thank you very much, @JanneM! With this fix, I was able to compile and run the software successfully on several different Linux systems successfully.

tysthomas commented 1 year ago

Thank you! Just what I needed on Mac OSX