rpms/glyph-keeper/devel glyph-keeper-0.29.1-fixes.patch, NONE, 1.1 glyph-keeper.spec, NONE, 1.1 .cvsignore, 1.1, 1.2 sources, 1.1, 1.2

Hans de Goede (jwrdegoede) fedora-extras-commits at redhat.com
Mon Mar 13 22:46:44 UTC 2006


Author: jwrdegoede

Update of /cvs/extras/rpms/glyph-keeper/devel
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv21117/devel

Modified Files:
	.cvsignore sources 
Added Files:
	glyph-keeper-0.29.1-fixes.patch glyph-keeper.spec 
Log Message:
auto-import glyph-keeper-0.29.1-2 on branch devel from glyph-keeper-0.29.1-2.src.rpm

glyph-keeper-0.29.1-fixes.patch:

--- NEW FILE glyph-keeper-0.29.1-fixes.patch ---
diff -ur glyph-keeper-0.29.1.orig/Makefile.GNU.all glyph-keeper-0.29.1/Makefile.GNU.all
--- glyph-keeper-0.29.1.orig/Makefile.GNU.all	2005-07-09 16:26:56.000000000 +0200
+++ glyph-keeper-0.29.1/Makefile.GNU.all	2006-03-11 17:11:10.000000000 +0100
@@ -66,13 +66,9 @@
 
 CC := gcc
 
-WFLAGS := -W -Wall
-
-OFLAGS := -O3 -s
-
 FT_CFLAGS := $(WFLAGS) -std=c89 $(OFLAGS) -Ifreetype/include $(ft_defines)
 
-GK_CFLAGS := $(WFLAGS) -std=c89 $(OFLAGS) -Iinclude $(gk_defines) $(if $(FT_LIB),,-Ifreetype/include)
+GK_CFLAGS := $(CFLAGS) -std=c89 -Iinclude $(gk_defines) $(if $(FT_LIB),,-Ifreetype/include)
 
 
 
Only in glyph-keeper-0.29.1: Makefile.GNU.all~
diff -ur glyph-keeper-0.29.1.orig/include/glyph.h glyph-keeper-0.29.1/include/glyph.h
--- glyph-keeper-0.29.1.orig/include/glyph.h	2005-07-09 15:02:50.000000000 +0200
+++ glyph-keeper-0.29.1/include/glyph.h	2006-03-11 19:13:38.000000000 +0100
@@ -149,7 +149,7 @@
 
 #elif (GLYPH_TARGET == GLYPH_TARGET_SDL)
 
-#include <sdl.h>
+#include <SDL/SDL.h>
 #define GLYPH_TARGET_STR        "SDL"
 #define GLYPH_TARGET_SURFACE    SDL_Surface
 #define GLYPH_TARGET_HAS_RECTFILL
Only in glyph-keeper-0.29.1/include: glyph.h~
Only in glyph-keeper-0.29.1: log
Only in glyph-keeper-0.29.1/obj: glyph-alleg.o
Only in glyph-keeper-0.29.1/obj: glyph-sdl.o
Only in glyph-keeper-0.29.1/obj: libglyph-alleg.a
Only in glyph-keeper-0.29.1/obj: libglyph-sdl.a
diff -ur glyph-keeper-0.29.1.orig/src/glyph_index.c glyph-keeper-0.29.1/src/glyph_index.c
--- glyph-keeper-0.29.1.orig/src/glyph_index.c	2005-06-24 11:35:00.000000000 +0200
+++ glyph-keeper-0.29.1/src/glyph_index.c	2006-03-11 19:11:04.000000000 +0100
@@ -58,13 +58,13 @@
     if (!index->pages) return size;
 
     size += 69*sizeof(void*);
-    if ((int)index->pages[68])
+    if ((long)index->pages[68])
     {
         for (a=0; a<68; a++)
         {
             if (!index->pages[a]) continue;
             size += 129*sizeof(void*);
-            if ((int)index->pages[a][128])
+            if ((long)index->pages[a][128])
             {
                 for (b=0; b<128; b++) { if (index->pages[a][b]) size += 129*sizeof(void*); }  
             }
@@ -220,7 +220,7 @@
 
     /* unlinking the glyph from index */
     page_c[c_index] = 0;
-    (*(int*)(page_c+128))--;
+    (*(long*)(page_c+128))--;
 
     /* uninking the glyph from keeper's list */
     if (glyph == keeper->head) keeper->head = keeper->head->next;
@@ -235,19 +235,19 @@
     free(glyph);
 
     /* releasing unnecessary index pages, and index itself */
-    if (((int)page_c[128])<=0)
+    if (((long)page_c[128])<=0)
     {
         free(page_c);
         page_b[b_index] = 0;
         keeper->allocated -= 129*sizeof(void*);
-        (*(int*)(page_b+128))--;
-        if (((int)page_b[128])<=0)
+        (*(long*)(page_b+128))--;
+        if (((long)page_b[128])<=0)
         {
             free(page_b);
             index->pages[a_index] = 0;
             keeper->allocated -= 129*sizeof(void*);
-            (*(int*)(index->pages+68))--;
-            if (((int)index->pages[68])<=0)
+            (*(long*)(index->pages+68))--;
+            if (((long)index->pages[68])<=0)
             {
                 free(index->pages);
                 index->pages = 0;
@@ -314,7 +314,7 @@
     {
         index->pages[a_index] = (GLYPH***)_gk_malloc(129*sizeof(void*));
         if (!index->pages[a_index]) return 0;
-        (*(int*)(index->pages+68))++;
+        (*(long*)(index->pages+68))++;
         memset(index->pages[a_index],0,129*sizeof(void*));
         keeper->allocated += 129*sizeof(void*);
     }
@@ -326,7 +326,7 @@
     {
         page_b[b_index] = (GLYPH**)_gk_malloc(129*sizeof(void*));
         if (!page_b[b_index]) return 0;
-        (*(int*)(page_b+128))++;
+        (*(long*)(page_b+128))++;
         memset(page_b[b_index],0,129*sizeof(void*));
         keeper->allocated += 129*sizeof(void*);
     }
@@ -338,7 +338,7 @@
     CARE(page_c[c_index]==0);
 
     page_c[c_index] = glyph;
-    (*(int*)(page_c+128))++;
+    (*(long*)(page_c+128))++;
     glyph->index = index;
 
     glyph->prev = 0;
@@ -512,7 +512,7 @@
     GLYPH_REND *rend;
     int ni = 0, nr = 0;
 
-    _gk_msg("GLYPH_KEEP object (address:%d):\n",(int)keeper);
+    _gk_msg("GLYPH_KEEP object (address:%p):\n", keeper);
 
     if (!keeper) return;
     _gk_msg("  can keep %d glyphs, currently keeping %d\n",keeper->max_glyphs,keeper->num_glyphs);
Only in glyph-keeper-0.29.1/src: glyph_index.c~


--- NEW FILE glyph-keeper.spec ---
Name:           glyph-keeper
Version:        0.29.1
Release:        2%{?dist}
Summary:        Library for text rendering
Group:          System Environment/Libraries
License:        zlib License
URL:            http://kd.lab.nig.ac.jp/glyph-keeper/
Source0:        http://kd.lab.nig.ac.jp/%{name}/files/%{name}-%{version}-no-freetype.zip
Patch0:         glyph-keeper-0.29.1-fixes.patch
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
BuildRequires:  freetype-devel >= 2.1.10
BuildRequires:  SDL-devel allegro-devel

%description
Glyph Keeper is a library for text rendering. It is written in C and can be 
used by C or C++ code. Glyph Keeper helps your program to load a font, render
character glyphs and write them to the target surface. Right now only Allegro
and SDL targets are supported, but there will be more in future. Glyph Keeper
uses FreeType as a font engine.


%package devel
Summary:        Library for text rendering
Group:          Development/Libraries
Requires:	allegro-devel SDL-devel

%description devel
Glyph Keeper is a library for text rendering. It is written in C and can be 
used by C or C++ code. Glyph Keeper helps your program to load a font, render
character glyphs and write them to the target surface. Right now only Allegro
and SDL targets are supported, but there will be more in future. Glyph Keeper
uses FreeType as a font engine.


%prep
%setup -q
%patch -p1


%build
make %{?_smp_mflags} -f Makefile.GNU.all TARGET=ALLEGRO FT_LIB=-lfreetype \
  CFLAGS="$RPM_OPT_FLAGS -I/usr/include/freetype2" lib

make %{?_smp_mflags} -f Makefile.GNU.all TARGET=SDL FT_LIB=-lfreetype \
  CFLAGS="$RPM_OPT_FLAGS -I/usr/include/freetype2" lib


%install
rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT%{_libdir}
mkdir -p $RPM_BUILD_ROOT%{_includedir}
install -m 644 obj/libglyph-*.a $RPM_BUILD_ROOT%{_libdir}
install -m 644 include/glyph.h $RPM_BUILD_ROOT%{_includedir}


%clean
rm -rf $RPM_BUILD_ROOT


%files devel
%defattr(-,root,root,-)
%doc license.txt changes.txt authors.txt docs/*
%{_includedir}/glyph.h
%{_libdir}/libglyph-*.a


%changelog
* Mon Mar 13 2006 Hans de Goede <j.w.r.degoede at hhs.nl> 0.29.1-2
-change license to "zlib License"
-add authors.txt and docs/* to %%doc

* Sat Mar 11 2006 Hans de Goede <j.w.r.degoede at hhs.nl> 0.29.1-1
- Initial Fedora Extras package


Index: .cvsignore
===================================================================
RCS file: /cvs/extras/rpms/glyph-keeper/devel/.cvsignore,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- .cvsignore	13 Mar 2006 22:45:57 -0000	1.1
+++ .cvsignore	13 Mar 2006 22:46:44 -0000	1.2
@@ -0,0 +1 @@
+glyph-keeper-0.29.1-no-freetype.zip


Index: sources
===================================================================
RCS file: /cvs/extras/rpms/glyph-keeper/devel/sources,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- sources	13 Mar 2006 22:45:57 -0000	1.1
+++ sources	13 Mar 2006 22:46:44 -0000	1.2
@@ -0,0 +1 @@
+e90e5103dce7d89aba2180bb830de8d9  glyph-keeper-0.29.1-no-freetype.zip




More information about the fedora-extras-commits mailing list