Skip to content

make fails with fatal error: opening dependency file bdsg/obj/eades_algorithm.d: No such file or directory due to non-existing directory #240

@paulmenzel

Description

@paulmenzel

Trying to build the project via the Makefile (not CMake) fails:

$ git log --oneline --no-decorate -1
c10ca5b Merge pull request #238 from vgteam/tip-orient
$ CXXFLAGS="-Ibdsg/deps/libhandlegraph/src/include -Ibdsg/deps/sdsl-lite/include/ -Ibdsg/deps/BBHash/ -Ibdsg/deps/sparsepp/ -Ibdsg/deps/mio/include/" make # just for demonstration
g++   -MMD -MP -O3 -Werror=return-type -std=c++14 -ggdb -g -Ibdsg/include -Ibdsg/deps/libhandlegraph/src/include -Ibdsg/deps/sdsl-lite/include/ -Ibdsg/deps/BBHash/ -Ibdsg/deps/sparsepp/ -Ibdsg/deps/mio/include/ -fopenmp -c bdsg/src/eades_algorithm.cpp -o bdsg/obj/eades_algorithm.o
bdsg/src/eades_algorithm.cpp:281:1: fatal error: opening dependency file bdsg/obj/eades_algorithm.d: No such file or directory
  281 | }
      | ^
compilation terminated.
make: *** [Makefile:73: bdsg/obj/eades_algorithm.o] Error 1

The target .pre-build is not executed:

libbdsg/Makefile

Lines 50 to 56 in c10ca5b

.pre-build:
@if [ ! -d $(LIB_DIR) ]; then mkdir -p $(LIB_DIR); fi
@if [ ! -d $(OBJ_DIR) ]; then mkdir -p $(OBJ_DIR); fi
@if [ ! -d $(BIN_DIR) ]; then mkdir -p $(BIN_DIR); fi
# run .pre-build before we make anything at all.
-include .pre-build

It’s unclear why -include is used, as that includes other files (commit 6c18203 (switch to make based build system)).

\cc @jeizenga

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions