After cmake improvement, we can not build for precise and saucy

Bug #1333885 reported by Jens Beyer
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
widelands
Fix Released
Undecided
Unassigned

Bug Description

After the major cmake upgrade, we lost Ubuntu Saucy and Precise.

For Saucy:
The target_include_directories with keyword SYSTEM needs at least cmake 2.8.12.1 to compile. Saucy only has 2.8.11.
The SYSTEM keyword is very nice for development, it silences a lot of warnings because the libraries are linked via System includes.
To me it looks like we *could* also do without the SYSTEM keyword, just with more warnings. My approach was therefor to make a small patch which removes all the SYSTEM keywords from the CMakeList.txt files. This patch should then be used by the launchpad builder to build Widelands for Saucy.
This way does not work for Precise, though.
We could go this way if we defined Saucy as compatible (providing packages for it) but not a supported development platform, and if we defined Precise as out of date for a target platform (we already had this discussion about LTS releases before...)

For Precise:
The whole target_include_directories is incompatible with cmake 2.8.7 which is the latest for Precise. SirVer's idea was to create some wrapper macros for Precise/Saucy which would use a different approach to link the libraries for systems which do not define target_include_directories.
This way we could keep Precise and Saucy as development platforms, but it would increase build system complexity.
I currently do also not know if target_include_directories is all we need to wrap for cmake 2.8.7 or if there is more into it.

What do you all think?

Tags: buildsystem

Related branches

Revision history for this message
SirVer (sirver) wrote :

Seems like saucy is cheap to implement. I think we should do it in the code base though, not through patches (as they will go out of date constantly) using the wrapper approach I suggested.

Precise I cannot judge really. I suggest spending 30 minutes trying to make our build system work (with warnings or not, we do not care there) and see it is reasonable to backport to cmake 2.8.7. Jens, could you do that?

Changed in widelands:
status: New → Incomplete
Revision history for this message
Jens Beyer (qcumber-some) wrote :

Ok I will go the wrapper macro way for saucy first, this should be pretty straight forward.
Then I can adapt this for Precise to see if this is possible.

Changed in widelands:
assignee: nobody → Jens Beyer (qcumber-some)
status: Incomplete → In Progress
Revision history for this message
Jens Beyer (qcumber-some) wrote :

For a start, Saucy is back.

Revision history for this message
Jens Beyer (qcumber-some) wrote :

...and Precise should be back. I can not wait for the build to run through, will check for it tomorrow.

Revision history for this message
SirVer (sirver) wrote :

looks good, one comment though: could you make two cmake functions? _include_directories and _include_system_directories() and hide the function taking the boolean in your private cmake files?

something like

function(_include_directories)
_include_directories_impl(... FALSE)
endfunction()

and vice versa for the system one.

reason is that booleans have no self documenting effect: I have to open your new cmake files to understand what the bool does.

Revision history for this message
Jens Beyer (qcumber-some) wrote :

oh of course, very good point. I will do that.

By the way, NOW precise is back ;-) I will implement the functions and remove some debug stuff and we are done.

Revision history for this message
Jens Beyer (qcumber-some) wrote :

Done.

Changed in widelands:
assignee: Jens Beyer (qcumber-some) → nobody
status: In Progress → Fix Committed
Revision history for this message
Hans Joachim Desserud (hjd) wrote :

Thanks for making it work on 12.04/13.10 again.

Changed in widelands:
milestone: none → build19-rc1
GunChleoc (gunchleoc)
tags: removed: cmake
GunChleoc (gunchleoc)
Changed in widelands:
status: Fix Committed → Fix Released
Revision history for this message
GunChleoc (gunchleoc) wrote :

Fixed in build19-rc1.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.