include dirs (Re: where to install the cmake files to ?)
Alexander Neundorf
neundorf at kde.org
Fri Feb 17 18:54:31 CET 2006
On Friday 17 February 2006 18:32, David Faure wrote:
> On Friday 17 February 2006 18:13, Alexander Neundorf wrote:
> > On Friday 17 February 2006 17:56, David Faure wrote:
> > ...
> >
> > > Looks fine, but we need to handle the case where the prefixes differ.
> > > If your cmake is in /usr and installed by root,
> > > and you install kdelibs as user into your home dir, then the cmake
> > > modules go into your home dir, not into the cmake dir, right?
> > > Then it's good - all that's needed is to be able to find them there....
> > > so we will probably need a piece of cmake configuration in every module
> > > which looks up the kde prefix, e.g. using kde-config.
> >
> > Yes, exactly.
> >
> > > But I would personally concentrate on cleaning up the CMakeLists.txt in
> > > kdelibs before expanding it to other modules,
> >
> > Do you have something special in mind which has to be cleaned up ?
>
> Well, I was thinking about the very large duplication of include dirs.
> am2cmake forgets that include_dirs are inherited from parent dirs,
Yes. It just translates file by file.
> so there's no need to specify all the things all the time.
> If we keep the stuff in kdelibs/CMakeFile.txt then a lot of include dirs
> can be removed from the subdirs. But maybe it's a bit strange to include
> all those dirs from there (e.g. kdecore sees kdeui and kio and kabc
> headers...)
If this is considered a problem then we couldn't change it...
> (And of course after the cmake fix for implicitly including the current dir
> we can clean that up even more)
>
> Still talking about include_directories, I foresee already that the
> Makefile.am problem of "all_includes is used before local includes" will
> appear in CMakeFiles too, it would nice to have a way to automate that so
> that every developer doesn't have to remember the rule of putting
> KDE4_INCLUDE_DIR last...
Why do you think that KDE4_INCLUDE_DIR has to be put last ?
If compiling kdelibs/, it points to ${CMAKE_INCLUDE_DIR}.
> Also, why is it kdelibs/kdecore/CMakeLists.txt which sets kde_datadir and
> kde_icondir etc.? Won't other modules need this as well?
The lower-case variables are just for the configure_file() call which creates
kde-config.cpp.
If the variables are used somewhere else, the ones from FindKDE4.cmake (in
cmake ALL_UPPER_CASE_STYLE are used).
Alex
--
Work: alexander.neundorf AT jenoptik.com - http://www.jenoptik-los.de
Home: neundorf AT kde.org - http://www.kde.org
alex AT neundorf.net - http://www.neundorf.net
More information about the Kde-buildsystem
mailing list