Project

General

Profile

Actions

Bug #10949

open

Building examples on linux

Added by Stefan Arndt over 1 year ago. Updated over 1 year ago.

Status:
New
Priority:
Low
Assignee:
-
Target version:
-
Start date:
09/16/2022
Due date:
% Done:

0%

Estimated time:

Description

Examples are not build under Linux unless -DINSTALL_EXAMPLES=ON is also set when configuring.

I would expect them to be build with that: cmake -S . -B build -DBUILD_EXAMPLES=ON or even cmake -S . -B build (since BUILD_EXAMPLES is on by default).
They are only build when using cmake -S . -B build -DBUILD_EXAMPLES=ON -DINSTALL_EXAMPLES=ON

Reading CMakeLists.txt:488 ff I can see the issue and I assume there have been reasons to treat the windows build differently - but that's inconvenient and reasons are not clear/documented.

Actions #1

Updated by Roel Standaert over 1 year ago

On non-Windows the examples are indeed not part of the all target.

You can actually build all examples by running make in the examples subdirectory of the build folder, or if you're using Ninja you can use the examples/all target.

I'm not sure why we're building all of the examples by default on Windows, maybe that's because of issues with CMake at the time. I would not build them by default on all platforms.

Actions

Also available in: Atom PDF