]> git.pld-linux.org Git - packages/dietlibc.git/blobdiff - dietlibc.spec
- added Pentium4 macro [by PawciooS].
[packages/dietlibc.git] / dietlibc.spec
index 42dad75bdc72852e56919d408ddb7d8caadcd927..81996d6570fcecab092b689bb585245765422072 100644 (file)
@@ -1,24 +1,32 @@
+%bcond_with    pp      # disable stack protector 'coz dietlibc will not work with it!
+
 Summary:       C library optimized for size
 Summary(pl):   Biblioteka standardowa C zoptymalizowana na rozmiar
 Summary(pt_BR):        libc pequena otimizada para tamanho
 Name:          dietlibc
-Version:       0.24
-Release:       3
+Version:       0.25
+Release:       1
 Epoch:         2
 License:       GPL v2
 Group:         Development/Libraries
 Source0:       http://www.kernel.org/pub/linux/libs/dietlibc/%{name}-%{version}.tar.bz2
-# Source0-md5: 1dc54e022c2b31fa99a512225ed36150
+# Source0-md5: a24c99d65b7443d17d0b15b74a1b39a0
+Source1:       %{name}-divrem.m4
 Patch0:                %{name}-ppc.patch
 Patch1:                %{name}-opt.patch
 Patch2:                %{name}-athlon.patch
 Patch3:                %{name}-amd64.patch
+Patch4:                %{name}-pentiumX.patch
 URL:           http://www.fefe.de/dietlibc/
+%ifarch sparc
+BuildRequires: m4
+BuildRequires: perl-base
+%endif
 BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %define                dietprefix      %{_prefix}/%{_target_cpu}-linux-dietlibc
 # for some reason known only to rpm there must be "\\|" not "\|" here
-%define                libarch         %(echo %{_target_cpu} | sed -e 's/i.86\\|athlon/i386/;s/amd64/x86_64/')
+%define                libarch         %(echo %{_target_cpu} | sed -e 's/i.86\\|pentium3\\|pentium4\\|athlon/i386/;s/amd64/x86_64/')
 
 %description
 Small libc for building embedded applications.
@@ -35,7 +43,7 @@ Summary:      Development files for dietlibc
 Summary(pl):   Pliki dla programistów u¿ywaj±cych dietlibc
 Summary(pt_BR):        libc pequena otimizada para tamanho
 Group:         Development/Libraries
-Requires:      %{name} = %{epoch}:%{version}
+Requires:      %{name} = %{epoch}:%{version}-%{release}
 
 %description devel
 Small libc for building embedded applications - development files.
@@ -48,7 +56,7 @@ programist
 Summary:       Static libraries for dietlibc
 Summary(pl):   Biblioteki statyczne dla dietlibc
 Group:         Development/Libraries
-Requires:      %{name}-devel = %{epoch}:%{version}
+Requires:      %{name}-devel = %{epoch}:%{version}-%{release}
 
 %description static
 Small libc for building embedded applications - static libraries.
@@ -63,9 +71,19 @@ statyczne.
 %patch1 -p1
 %patch2 -p1
 %patch3 -p1
+%patch4 -p1
+
+%ifarch sparc
+# generate missing functions
+(echo "define(NAME,\`.div')define(OP,\`div')define(S,\`true')"; cat %{SOURCE1}) \
+       | m4 > sparc/sdiv.S
+(echo "define(NAME,\`.rem')define(OP,\`rem')define(S,\`true')"; cat %{SOURCE1}) \
+       | m4 > sparc/srem.S
+%{__perl} -pi -e 's@(^LIBOBJ.*$)@$1 \$(OBJDIR)/sdiv.o \$(OBJDIR)/srem.o@' sparc/Makefile.add
+%endif
 
 %build
-OPTFLAGS="%{rpmcflags}"; export OPTFLAGS
+OPTFLAGS="%{rpmcflags} %{?with_pp:-fno-stack-protector}"; export OPTFLAGS
 %ifarch sparc sparcv9
 sparc32 \
 %endif
This page took 0.045698 seconds and 4 git commands to generate.