]> git.pld-linux.org Git - packages/STLport.git/blobdiff - STLport.spec
- stlport doesn't require libstdc++ runtime.
[packages/STLport.git] / STLport.spec
index 367906dd51a8a573e6bbd03b4437a5f0a11bf4f2..a9f2530d2750f304dc1738f7ef9271084efb1aef 100644 (file)
@@ -1,3 +1,7 @@
+#
+# Conditional build:
+%bcond_with    static_gcc      # linkg libgcc* statically into libstlport.
+#
 Summary:       C++ standard library
 Summary(pl.UTF-8):     Biblioteki standardowe C++
 Name:          STLport
@@ -11,10 +15,10 @@ Source0:    http://dl.sourceforge.net/stlport/%{name}-%{version}.tar.bz2
 Patch0:                %{name}-endianness.patch
 Patch1:                %{name}-alpha.patch
 Patch2:                %{name}-valarray-copy-constructor.patch
+Patch3:                %{name}-vendor_gcc_detection.patch
 URL:           http://stlport.sourceforge.net/
 BuildRequires: libstdc++-devel >= 6:4.2.0-1
 BuildRequires: sed >= 4.0
-%requires_eq   libstdc++
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
@@ -54,7 +58,6 @@ Biblioteki statyczne do STLport.
 Summary:       Debug version of STLport library
 Summary(pl.UTF-8):     Wersja diagnostyczna biblioteki STLport
 Group:         Libraries
-%requires_eq   libstdc++
 
 %description dbg
 Debug version of STLport library.
@@ -92,11 +95,16 @@ Statyczna wersja diagnostyczna biblioteki STLport.
 %patch0 -p1
 %patch1 -p1
 %patch2 -p1
+%patch3 -p1
 
 sed -i -e 's/= -O2$/= %{rpmcflags}/' build/Makefiles/gmake/gcc.mak
 
 %build
-%{__make} -C build/lib -f gcc.mak \
+cd build/lib
+
+%{?with_static_gcc:./configure --use-static-gcc}
+
+%{__make} -f gcc.mak \
        stldbg-shared \
        stldbg-static \
        release-shared \
@@ -104,6 +112,8 @@ sed -i -e 's/= -O2$/= %{rpmcflags}/' build/Makefiles/gmake/gcc.mak
        CC="%{__cc}" \
        CXX="%{__cxx}"
 
+cd ../..
+
 %install
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT%{_includedir}
This page took 0.085618 seconds and 4 git commands to generate.