Fixed a build issue

This commit is contained in:
Ravindra Kumar 2015-09-14 20:39:59 -07:00
parent ba51a75a8d
commit 21b0b63fc3

View File

@ -28,7 +28,7 @@
Name: open-vm-tools Name: open-vm-tools
Version: %{toolsversion} Version: %{toolsversion}
Release: 2%{?dist} Release: 3%{?dist}
Summary: Open Virtual Machine Tools for virtual machines hosted on VMware Summary: Open Virtual Machine Tools for virtual machines hosted on VMware
Group: Applications/System Group: Applications/System
License: GPLv2 License: GPLv2
@ -116,11 +116,13 @@ VMware virtual machines.
%setup -q -n %{name}-%{version}-%{toolsbuild} %setup -q -n %{name}-%{version}-%{toolsbuild}
%build %build
# Use _DEFAULT_SOURCE to suppress warning until upstream # Fedora 23 uses libsigc++-2.0 version 2.6.1.
# is fixed. Refer https://sourceware.org/bugzilla/show_bug.cgi?id=16632. # libsigc++-2.0 >= 2.5.1 requires C++11. Using
export CFLAGS="$RPM_OPT_FLAGS -D_DEFAULT_SOURCE" # -std=c++11 does not provide "linux" definition
# Some sigc++-2.0 headers need C++11 # therefore, we need to use -std=gnu++11
export CXXFLAGS="$RPM_OPT_FLAGS -D_DEFAULT_SOURCE -std=c++11" %if 0%{?fedora} >= 23
export CXXFLAGS="$RPM_OPT_FLAGS -std=gnu++11"
%endif
# Required for regenerating configure script when # Required for regenerating configure script when
# configure.ac get modified # configure.ac get modified
autoreconf -i autoreconf -i
@ -259,6 +261,12 @@ fi
%{_libdir}/libvmtools.so %{_libdir}/libvmtools.so
%changelog %changelog
* Wed Sep 30 2015 Ravindra Kumar <ravindrakumar@vmware.com> - 10.0.0-3
- Replace -std=c++11 with -std=gnu++11 to get "linux" definitions work
in order to fix the build issue,
https://kojipkgs.fedoraproject.org//work/tasks/4823/11274823/build.log
- Removed unused definitions for CFLAGS and CXXFLAGS
* Wed Sep 30 2015 Ravindra Kumar <ravindrakumar@vmware.com> - 10.0.0-2 * Wed Sep 30 2015 Ravindra Kumar <ravindrakumar@vmware.com> - 10.0.0-2
- Add -std=c++11 to CXXFLAGS for fixing the build issue, - Add -std=c++11 to CXXFLAGS for fixing the build issue,
https://kojipkgs.fedoraproject.org//work/tasks/3685/11273685/build.log https://kojipkgs.fedoraproject.org//work/tasks/3685/11273685/build.log