[fswebcam/f13/master] Add patches the right way

Fabian Affolter fab at fedoraproject.org
Wed Sep 1 19:48:31 UTC 2010


commit 11d4a18244fe5a8ef3d0e6f60f026036ee7c60ac
Author: Fabian Affolter <fab at fedoraproject.org>
Date:   Wed Sep 1 21:48:13 2010 +0200

    Add patches the right way

 .gitignore          |    2 --
 fswebcam-font.patch |   12 ++++++++++++
 fswebcam-man.patch  |   11 +++++++++++
 fswebcam.spec       |    8 ++++----
 sources             |    2 --
 5 files changed, 27 insertions(+), 8 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index f4c28b7..74b87a6 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,3 +1 @@
 fswebcam-20091224.tar.gz
-/fswebcam-font.patch
-/fswebcam-man.patch
diff --git a/fswebcam-font.patch b/fswebcam-font.patch
new file mode 100644
index 0000000..d25cda4
--- /dev/null
+++ b/fswebcam-font.patch
@@ -0,0 +1,12 @@
+--- fswebcam-20100622/fswebcam.c.orig	2010-05-12 13:03:42.000000000 +0200
++++ fswebcam-20100622/fswebcam.c	2010-08-31 21:24:19.270382863 +0200
+@@ -1591,6 +1591,9 @@
+ 	/* Setup signal handlers. */
+ 	if(fswc_setup_signals()) return(-1);
+ 	
++	/* Enable FontConfig support in GD */
++	if(!gdFTUseFontConfig(1)) DEBUG("gd has no fontconfig support");
++
+ 	/* Capture the image(s). */
+ 	if(!config->loop) fswc_grab(config);
+ 	else
diff --git a/fswebcam-man.patch b/fswebcam-man.patch
new file mode 100644
index 0000000..3fde3ce
--- /dev/null
+++ b/fswebcam-man.patch
@@ -0,0 +1,11 @@
+--- fswebcam-20100622/fswebcam.1.orig	2010-06-22 12:01:49.000000000 +0200
++++ fswebcam-20100622/fswebcam.1	2010-08-31 21:24:05.927372771 +0200
+@@ -269,7 +269,7 @@
+ 
+ .TP
+ \fB\-\-font\fR \fI<[file or font name]:[font size]>\fR
+-Set the font used in the banner. If no path is specified the path in the GDFONTPATH environment variable is searched for the font.
++Set the font used in the banner. If no path is specified the path in the GDFONTPATH environment variable is searched for the font. Fontconfig names may also be used if the GD library has support.
+ .IP
+ If no font size is specified the default of "10" will be used.
+ .IP
diff --git a/fswebcam.spec b/fswebcam.spec
index c1fbced..39c9a5b 100644
--- a/fswebcam.spec
+++ b/fswebcam.spec
@@ -7,8 +7,8 @@ Group:          Applications/System
 License:        GPLv2
 URL:            http://www.firestorm.cx/fswebcam/
 Source0:        http://www.firestorm.cx/%{name}/files/%{name}-%{version}.tar.gz
-Patch0:         fswebcam-font.patch
-Patch1:         fswebcam-man.patch
+Patch0:         %{name}-font.patch
+Patch1:         %{name}-man.patch
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildRequires:  gd-devel
@@ -21,8 +21,8 @@ device, and overlaying a caption or image.
 
 %prep
 %setup -q
-%patch0 -p0 -b .font
-%patch0 -p0 -b .man
+%patch0 -p1 -b .font
+%patch1 -p1 -b .man
 
 
 %build
diff --git a/sources b/sources
index c915525..a06ebb2 100644
--- a/sources
+++ b/sources
@@ -1,3 +1 @@
 fe3a34458905bc5e9bb2d75c0d44790c  fswebcam-20100401.tar.gz
-0607c505d7ff42b78df65f5b1221073b  fswebcam-font.patch
-9a0a80f99fdda1f196bb43a175e098f7  fswebcam-man.patch


More information about the scm-commits mailing list