We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 3651 - CMake build does not install CMake package configuration
Summary: CMake build does not install CMake package configuration
Status: RESOLVED FIXED
Alias: None
Product: SDL
Classification: Unclassified
Component: build (show other bugs)
Version: HG 2.1
Hardware: All All
: P2 normal
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords: target-2.0.6
Depends on:
Blocks:
 
Reported: 2017-05-14 18:48 UTC by tschwinger
Modified: 2017-08-10 04:02 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description tschwinger 2017-05-14 18:48:53 UTC
Most ironically, although autoconf/automake-based builds install (pretty half-assed) CMake package configuration files, they're missing in installations resulting from CMake-based builds entirely.

A proper configuration file typically also loads target exports (implemented in patch 3572, also fixing this issue - see my comment on that issue for details).

I believe it would be best to let the dinosaurs go extinct and redirect all build efforts to the CMake end for two reasons:

1. It potentially provides the best user experience, but you'd have to give it some love and ship with less quirky buildfiles.

2. It would force distros to build SDL via CMake and thus would ensure target exports are actually available everywhere.
Comment 1 tschwinger 2017-05-15 00:01:53 UTC
Various CMake patches I submitted today in summary (directly converted from the HG commits and `am`d onto a fork of a git mirror that happened to be on `tip`).

    https://github.com/tschw/SDL/commits/patched

Fixing #2576 #3572, #3613, and this fresh ticket, which is almost entirely advertisement ;).

These already do to make SDL much less of a quirky fella to have in your dependency tree...
Comment 2 Ryan C. Gordon 2017-08-09 05:25:35 UTC
(Sorry if you get a lot of copies of this email, we're touching dozens of bug reports right now.)

Tagging a bunch of bugs as target-2.0.6.

This means we're in the final stretch for an official SDL 2.0.6 release! These are the bugs we really want to fix before shipping if humanly possible.

That being said, we don't promise to fix them because of this tag, we just want to make sure we don't forget to deal with them before we bless a final 2.0.6 release, and generally be organized about what we're aiming to ship. After some debate, we might just remove this tag again and deal with it for a later release.

Hopefully you'll hear more about this bug soon. If you have more information (including "this got fixed at some point, nevermind"), we would love to have you come add more information to the bug report when you have a moment.

Thanks!
--ryan.
Comment 3 Sam Lantinga 2017-08-10 02:03:36 UTC
Patch applied, thanks!
https://hg.libsdl.org/SDL/rev/c92070a96da5
Comment 4 Ryan C. Gordon 2017-08-10 02:40:50 UTC
+if (APPLE)
+  set(PKG_PREFIX "SDL2.framework/Resources")

We aren't building a framework with the CMake projects on macOS at the moment, so this piece probably isn't right.

--ryan.
Comment 5 Ryan C. Gordon 2017-08-10 04:02:56 UTC
> We aren't building a framework with the CMake projects on macOS at the
> moment, so this piece probably isn't right.

(Also, maybe we don't care about installing CMake pieces on macOS in any case.)