Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with 3rd party compilation order #3802

Open
lars18th opened this issue Dec 2, 2024 · 1 comment
Open

Issues with 3rd party compilation order #3802

lars18th opened this issue Dec 2, 2024 · 1 comment

Comments

@lars18th
Copy link

lars18th commented Dec 2, 2024

Describe the bug
Manually compiling Multipass the build process stops at some point.

To Reproduce
Inside one Ubuntu 20.04 container, the build process compiling with CLang stops with this error:

-- Looking for openssl/des.h - not found
CMake Error at 3rd-party/libssh/libssh/ConfigureChecks.cmake:80 (message):
  Could not detect openssl/des.h
Call Stack (most recent call first):
  3rd-party/libssh/CMakeLists.txt:51 (include)

Expected behavior
The problem seems to be related to the order of the 3rd party components:

multipass/CMakeLists.txt

Lines 125 to 138 in 6c4b8b4

# OpenSSL config
find_package(OpenSSL REQUIRED)
# gRPC config
find_package(gRPC CONFIG REQUIRED)
# Needs to be here before we set further compilation options
add_subdirectory(3rd-party)
# Qt config
find_package(Qt6 COMPONENTS Core Concurrent Network REQUIRED)
# POCO config
find_package(Poco REQUIRED COMPONENTS Foundation Zip)

If you check the pre-builded vcpkg-ports 3rd party package, it includes custom grpc and poco packages as well. However, the configuration is not using these libs to compile other 3rd party packages. And the same is true for the libssh.

The idea is then: compile first custom libssh, grpc and poco; and after use only these versions to compile all the other dependencies.

I hope you want to improve the compilation process to reduce dependencies and use only the custom build 3rd party libraries. This could facilitate compilation in other environments and reduce compilation time.

@lars18th lars18th added bug needs triage Issue needs to be triaged labels Dec 2, 2024
@giuliazanchi giuliazanchi added enhancement good first issue and removed bug needs triage Issue needs to be triaged labels Dec 3, 2024
@giuliazanchi
Copy link
Contributor

Hi @lars18th , thanks for bringing this to our attention, it's definitely worth exploring further to simplify and improve the build process and, possibly, the build instructions.
Since you seem to have investigated the problem and possible solutions, feel free to open a PR and suggest a fix, we're always happy to review and incorporate contributions from the community.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants