SPECS: cmake.spec - even more :/

Tomasz Wittner tomasz.wittner at gmail.com
Thu Jul 31 15:06:55 CEST 2008


On Thursday 31 of July 2008, 08:54, Elan Ruusamäe wrote:
> On Thursday 31 July 2008 07:45, qboosh wrote:
> > +# - rpmldflags/rpmcppflags are not passed through %%cmake macro at all
> > +#   (is there any standard way???)
>
> there isn't (this has gone over devel-en list already at least twice).
>
> however i've tried to use in few places our standard, ie the ones we use in
> autoconf:
>
> # override __cmake to add -j4 in your ~/.rpmmacros for parallel make
> %__cmake    /usr/bin/cmake
> %cmake { \
> CC="%{__cc}" \
> CXX="%{__cxx}" \
> CFLAGS="%{rpmcflags}" \
> CXXFLAGS="%{rpmcxxflags}" \
> %{__cmake} \
> }
>
> another place i recall, where these compiler options are not accepted is
> apache modules via apxs, they use cc and flags from apache compile time.

The same story with ruby packages - most of them use ruby script which takes 
values of CC, CXX, C(XX)FLAGS from Config module 
(file /usr/lib/ruby/1.8/*-linux/rbconfig.rb). IMO there is no way other than 
patching these setup scripts one by one to accept CC, CXX, C(XX)FLAGS env. 
var. or taking flags via commandline switchs - IMO such patching doesn't pay, 
there is only one practical inconvenience which is raleted to passing CC/CXX 
values when ccache is used without symlinking compilers commands to ccache.

-- 
Tomasz Wittner


More information about the pld-devel-en mailing list