diff options
author | Alexandre Oliva <lxoliva@fsfla.org> | 2012-03-22 16:23:02 -0300 |
---|---|---|
committer | Sage Weil <sage.weil@dreamhost.com> | 2012-03-25 07:57:39 -0700 |
commit | 3ab28950beabe9d452da35ec2f2d583751764a9a (patch) | |
tree | a6e22e5ee512a0a8ee53c6154a34a2bbe5620413 /ceph.spec.in | |
parent | d3bcac241f25f681a585c2115a79befe43dd7d6c (diff) | |
download | ceph-3ab28950beabe9d452da35ec2f2d583751764a9a.tar.gz |
don't override CFLAGS
leveldb adds -I flags to CFLAGS and CXXFLAGS, but if these macros are
overridden in the make command line, the flags are dropped, and the
build fails. leveldb should probably use AM_CFLAGS instead, but the
spec file can specify the preferred CFLAGS in the configure command
line, and then everything will work as expected.
Signed-off-by: Alexandre Oliva <oliva@lsd.ic.unicamp.br>
Signed-off-by: Sage Weil <sage.weil@dreamhost.com>
Diffstat (limited to 'ceph.spec.in')
-rw-r--r-- | ceph.spec.in | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/ceph.spec.in b/ceph.spec.in index b8b2d1fd227..e5df113bf67 100644 --- a/ceph.spec.in +++ b/ceph.spec.in @@ -217,6 +217,8 @@ MY_CONF_OPT="$MY_CONF_OPT --with-gtk2" MY_CONF_OPT="$MY_CONF_OPT --without-gtk2" %endif +export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed -e 's/i386/i486/'` + # be explicit about --with/without-tcmalloc because the # autoconf default differs from what's needed for rpm %{configure} --prefix=/usr \ @@ -227,7 +229,8 @@ MY_CONF_OPT="$MY_CONF_OPT --without-gtk2" --without-hadoop \ $MY_CONF_OPT \ %{?_with_ocf} \ - %{?with_tcmalloc:--with-tcmalloc} %{!?with_tcmalloc:--without-tcmalloc} + %{?with_tcmalloc:--with-tcmalloc} %{!?with_tcmalloc:--without-tcmalloc} \ + CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" # fix bug in specific version of libedit-devel %if 0%{defined suse_version} @@ -236,9 +239,7 @@ sed -i -e "s/-lcurses/-lncurses/g" src/Makefile sed -i -e "s/-lcurses/-lncurses/g" man/Makefile %endif -export RPM_OPT_FLAGS=`echo $RPM_OPT_FLAGS | sed -e 's/i386/i486/'` - -make -j$(getconf _NPROCESSORS_ONLN) CFLAGS="$RPM_OPT_FLAGS" CXXFLAGS="$RPM_OPT_FLAGS" +make -j$(getconf _NPROCESSORS_ONLN) %install make DESTDIR=$RPM_BUILD_ROOT install |