[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-buildsystem
Subject:    Re: cmake resets variables
From:       Alexander Neundorf <neundorf () kde ! org>
Date:       2007-11-06 23:25:42
Message-ID: 200711070025.42870.neundorf () kde ! org
[Download RAW message or body]

On Tuesday 06 November 2007, Thiago Macieira wrote:
> Em Tuesday 06 November 2007 14:23:03 Lubos Lunak escreveu:
> >  Hello,
> >
> >  since kBacktrace() is not that useful with hidden symbols, I explicitly
> > run cmake with -D__KDE_HAVE_GCC_VISIBILITY=0, which turns it off.
> > However, any single change to any CMakeLists.txt re-runs automatically
> > cmake, which also runs the cmake test for hidden symbols and enables them
> > (interestingly, after yet another change it doesn't run it again). I
> > always get undefined symbols as a result of this and I'm getting kind of
> > tired of running cmake manually all the time.
> >
> >  Does somebody know how to fix this?
>
> Make the variable cached.

and put a flag variable in the cache which signals "test already done".
Like:

IF(NOT DEFINED GCC_VISIBILITY_TEST_DONE)
   ... do the test
   set(GCC_VISIBILITY_TEST_DONE TRUE CACHE BOOL "Test done")
ENDIF(NOT DEFINED GCC_VISIBILITY_TEST_DONE)


Alex

_______________________________________________
Kde-buildsystem mailing list
Kde-buildsystem@kde.org
https://mail.kde.org/mailman/listinfo/kde-buildsystem
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic