From 1861542215f20bb7fd88df86b5a1f4cf13d528d0 Mon Sep 17 00:00:00 2001 From: Lubomir Rintel Date: Mar 02 2010 14:25:22 +0000 Subject: - Fix link with new linker - Fix incorrect memset() arguments - Fix parallel build --- diff --git a/tuxpaint-0.9.21-link.patch b/tuxpaint-0.9.21-link.patch new file mode 100644 index 0000000..4382474 --- /dev/null +++ b/tuxpaint-0.9.21-link.patch @@ -0,0 +1,32 @@ +From f537219097c499a38d8a4a2b06c14a6e9d54605c Mon Sep 17 00:00:00 2001 +From: Lubomir Rintel +Date: Tue, 2 Mar 2010 12:52:01 +0100 +Subject: [PATCH] Fix link + +--- + Makefile | 8 +++++--- + 1 files changed, 5 insertions(+), 3 deletions(-) + +diff --git a/Makefile b/Makefile +index 67be2ba..52d0f40 100644 +--- a/Makefile ++++ b/Makefile +@@ -77,10 +77,12 @@ PNG:=$(if $(PNG),$(PNG),$(call linktest,-lpng12,)) + FRIBIDI_LIB:=$(shell pkg-config --libs fribidi) + FRIBIDI_CFLAGS:=$(shell pkg-config --cflags fribidi) + +-windows_ARCH_LINKS:=-lintl $(PNG) -lwinspool -lshlwapi $(FRIBIDI_LIB) ++COMMON_LIB=-lm -lz ++ ++windows_ARCH_LINKS:=-lintl $(PNG) -lwinspool -lshlwapi $(FRIBIDI_LIB) + osx_ARCH_LINKS:=$(PAPER_LIB) $(FRIBIDI_LIB) +-beos_ARCH_LINKS:="-lintl $(PNG) -lz -lbe -liconv $(FRIBIDI_LIB)" +-linux_ARCH_LINKS:=$(PAPER_LIB) $(FRIBIDI_LIB) ++beos_ARCH_LINKS:=-lintl $(PNG) -lbe -liconv $(FRIBIDI_LIB) $(COMMON_LIB) ++linux_ARCH_LINKS:=$(PNG) $(FRIBIDI_LIB) $(PAPER_LIB) $(COMMON_LIB) + ARCH_LINKS:=$($(OS)_ARCH_LINKS) + + windows_ARCH_HEADERS:=src/win32_print.h +-- +1.7.0 + diff --git a/tuxpaint-0.9.21-makej.patch b/tuxpaint-0.9.21-makej.patch new file mode 100644 index 0000000..a93e530 --- /dev/null +++ b/tuxpaint-0.9.21-makej.patch @@ -0,0 +1,25 @@ +From edc3e418521bd65ccc67a133f8a980a8f013e394 Mon Sep 17 00:00:00 2001 +From: Lubomir Rintel +Date: Tue, 2 Mar 2010 13:43:39 +0100 +Subject: [PATCH] Fix translation parallel build race + +--- + Makefile | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/Makefile b/Makefile +index 563dded..52d0f40 100644 +--- a/Makefile ++++ b/Makefile +@@ -370,7 +370,7 @@ endif + + # Build the translation files for gettext + +-$(MOFILES): trans/%.mo: src/po/%.po ++$(MOFILES): trans/%.mo: src/po/%.po trans + msgfmt -o $@ $< + + .PHONY: translations +-- +1.7.0 + diff --git a/tuxpaint-0.9.21-memset.patch b/tuxpaint-0.9.21-memset.patch new file mode 100644 index 0000000..4396cc3 --- /dev/null +++ b/tuxpaint-0.9.21-memset.patch @@ -0,0 +1,25 @@ +From da064f6c8b2bcbc7f8fb00fbdc49ba3b2f0543ac Mon Sep 17 00:00:00 2001 +From: Lubomir Rintel +Date: Tue, 2 Mar 2010 12:54:08 +0100 +Subject: [PATCH 2/2] Fix memset argument order + +--- + src/tuxpaint.c | 2 +- + 1 files changed, 1 insertions(+), 1 deletions(-) + +diff --git a/src/tuxpaint.c b/src/tuxpaint.c +index 6047cbb..145fb10 100644 +--- a/src/tuxpaint.c ++++ b/src/tuxpaint.c +@@ -1130,7 +1130,7 @@ static SDL_Surface *render_text_w(TuxPaint_Font * restrict font, + + utfstr_max = (sizeof(char) * 4 * (wcslen(str) + 1)); + utfstr = (char *) malloc(utfstr_max); +- memset(utfstr, utfstr_max, 0); ++ memset(utfstr, 0, utfstr_max); + + j = 0; + for (i = 0; i < wcslen(str); i++) +-- +1.7.0 + diff --git a/tuxpaint.spec b/tuxpaint.spec index 9161d25..b0395e4 100644 --- a/tuxpaint.spec +++ b/tuxpaint.spec @@ -1,6 +1,6 @@ Name: tuxpaint Version: 0.9.21 -Release: 2%{?dist} +Release: 3%{?dist} Epoch: 1 Summary: Drawing program designed for young children @@ -11,6 +11,11 @@ URL: http://www.tuxpaint.org/ Source0: http://dl.sf.net/%{name}/%{name}-%{version}.tar.gz Patch0: tuxpaint-utf8.patch Patch1: tuxpaint-0.9.21-fix-desktop-file.patch +Patch2: tuxpaint-0.9.21-link.patch +Patch3: tuxpaint-0.9.21-makej.patch +Patch4: tuxpaint-0.9.21-memset.patch + + BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) BuildRequires: SDL-devel >= 1.2.4 @@ -48,6 +53,9 @@ Development files for tuxpaint extensions/plugins %setup -q %patch0 -p1 %patch1 -p0 -b .fixdesktopfile +%patch2 -p1 -b .link +%patch3 -p1 -b .makej +%patch4 -p1 -b .memset sed -i -e '/\/gnome\/apps\/Graphics/d' Makefile find docs -type f -exec perl -pi -e 's/\r\n/\n/' {} \; @@ -105,6 +113,11 @@ rm -rf $RPM_BUILD_ROOT %{_includedir}/tuxpaint/ %changelog +* Tue Mar 3 2010 Lubomir Rintel - 1:0.9.21-3 +- Fix link with new linker +- Fix incorrect memset() arguments +- Fix parallel build + * Thu Nov 19 2009 Jon Ciesla - 1:0.9.21-2 - Corrected icon requires, BZ 533965.