Skip to content

Possible missing dependency: libstdc++-12-dev #34

@hikalium

Description

@hikalium

I hit following failure during ./zen-release build deps:

*** cd /work/zen-release-manager/build/grpc-dev
...
*** make native
cmake \
	-B build/native/Debug \
	-DCMAKE_INSTALL_PREFIX=/work/zen-release-manager/build/grpc-dev/native/Debug \
	-DCMAKE_BUILD_TYPE=Debug \
	-GNinja \
	./grpc
...
-- Check for working CXX compiler: /usr/bin/clang++ - broken
...
    FAILED: cmTC_9e889 
    : && /usr/bin/clang++   CMakeFiles/cmTC_9e889.dir/testCXXCompiler.cxx.o -o cmTC_9e889   && :
    /usr/bin/ld: cannot find -lstdc++: No such file or directory
    clang: error: linker command failed with exit code 1 (use -v to see invocation)
    ninja: build stopped: subcommand failed.

After a bit of research, it looks like it happens when libstdc++ is not installed while both gcc and clang are installed.

c.f. https://stackoverflow.com/questions/74543715/usr-bin-ld-cannot-find-lstdc-no-such-file-or-directory-on-running-flutte

and installing one of libstdc++ explicitly solved the problem:

sudo apt install libstdc++-12-dev

Not sure what is the best way to ensure a proper version of libstdc++ is installed regardless which version of clang is installed, reporting this just in case if anyone hits the same issue. (Feel free to close / archive.)

full log: https://gist.github.com/hikalium/1e0b41098bfd7da9100ca6ed5e1cdac1

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions