aboutsummaryrefslogtreecommitdiffstats
path: root/devel/gauche-sdl
diff options
context:
space:
mode:
authoredwin <edwin@FreeBSD.org>2006-01-03 06:23:19 +0800
committeredwin <edwin@FreeBSD.org>2006-01-03 06:23:19 +0800
commit30d82a6162455200357e808f01161a2b8cc7a00c (patch)
tree6146e69c54e3db5073b3a6f53f488cceb5b6b862 /devel/gauche-sdl
parent2f6043e088834d51376b1bf31b8dbd82a3e7bc5a (diff)
downloadfreebsd-ports-gnome-30d82a6162455200357e808f01161a2b8cc7a00c.tar.gz
freebsd-ports-gnome-30d82a6162455200357e808f01161a2b8cc7a00c.tar.zst
freebsd-ports-gnome-30d82a6162455200357e808f01161a2b8cc7a00c.zip
[Maintainer Update] devel/gauche-sdl fixed compiler error
devel/gauche-sdl was broken after a lang/gauche update due to changes in how strings are internally represented. This updates string access in the stub files, allowing it to compile again. (the gfx subdir is still not fixed, so it's being forcefully bypassed). (author will be notified as soon as I get a pr # to give him) PR: ports/91228 Submitted by: Erik Greenwald <erik@smluc.org>
Diffstat (limited to 'devel/gauche-sdl')
-rw-r--r--devel/gauche-sdl/Makefile4
-rw-r--r--devel/gauche-sdl/files/patch-configure58
-rw-r--r--devel/gauche-sdl/files/patch-src::image::sdl-image-lib.stub20
-rw-r--r--devel/gauche-sdl/files/patch-src::sdl-lib.stub60
4 files changed, 135 insertions, 7 deletions
diff --git a/devel/gauche-sdl/Makefile b/devel/gauche-sdl/Makefile
index bc67c9899d47..bb98b1c71a8c 100644
--- a/devel/gauche-sdl/Makefile
+++ b/devel/gauche-sdl/Makefile
@@ -19,8 +19,6 @@ BUILD_DEPENDS= gosh:${PORTSDIR}/lang/gauche \
RUN_DEPENDS= gosh:${PORTSDIR}/lang/gauche \
${X11BASE}/lib/X11/rgb.txt:${X_CLIENTS_PORT}
-BROKEN= Does not compile
-
PLIST_SUB= GAUCHE_VERSION="`gauche-config -V`"\
TARGET="${CONFIGURE_TARGET}"
WRKSRC= ${WRKDIR}/${PORTFAKENAME}
@@ -40,5 +38,7 @@ pre-configure:
-e "s|SDL/SDL|SDL|g"\
-e "s|%%SDL_CFLAGS%%|`${SDL_CONFIG} --cflags`|"\
${WRKSRC}/configure
+ ${REINPLACE_CMD} -e "s|^CFLAGS.*|& `${SDL_CONFIG} --cflags`|" \
+ ${WRKSRC}/src/gfx/Makefile.in
.include <bsd.port.mk>
diff --git a/devel/gauche-sdl/files/patch-configure b/devel/gauche-sdl/files/patch-configure
index dcf75844da2d..283fe0a9a6a2 100644
--- a/devel/gauche-sdl/files/patch-configure
+++ b/devel/gauche-sdl/files/patch-configure
@@ -1,14 +1,62 @@
---- configure.orig Sun Feb 15 16:47:50 2004
-+++ configure Sun Feb 15 16:49:38 2004
-@@ -777,6 +777,8 @@
+--- configure.orig Tue Jan 21 23:22:40 2003
++++ configure Mon Jan 2 04:06:03 2006
+@@ -737,7 +737,7 @@
+ fi
+ echo "$ac_t""$CPP" 1>&6
+
+-for ac_hdr in SDL/SDL.h
++for ac_hdr in SDL.h
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+@@ -777,8 +777,10 @@
fi
done
+MYLAMEOLDCPPFLAGS="${CPPFLAGS}"
-+CPPFLAGS="${CPPFLAGS} %%SDL_CFLAGS%%"
++CPPFLAGS="${CPPFLAGS} -I/usr/local/include/SDL11 -I/usr/local/include -D_REENTRANT"
+
+-for ac_hdr in SDL/SDL_framerate.h
++for ac_hdr in SDL_framerate.h
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+@@ -812,7 +814,7 @@
+ cat >> confdefs.h <<EOF
+ #define $ac_tr_hdr 1
+ EOF
+- HAVE_SDL_GFX=1
++# HAVE_SDL_GFX=1
+ else
+ echo "$ac_t""no" 1>&6
+ fi
+@@ -820,7 +822,7 @@
+
+
+
+-for ac_hdr in SDL/SDL_image.h
++for ac_hdr in SDL_image.h
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+@@ -862,7 +864,7 @@
+
+
+
+-for ac_hdr in SDL/SDL_mixer.h
++for ac_hdr in SDL_mixer.h
+ do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
+@@ -904,7 +906,7 @@
+
+
- for ac_hdr in SDL/SDL_framerate.h
+-for ac_hdr in SDL/SDL_ttf.h
++for ac_hdr in SDL_ttf.h
do
+ ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
+ echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
@@ -944,7 +946,7 @@
fi
done
diff --git a/devel/gauche-sdl/files/patch-src::image::sdl-image-lib.stub b/devel/gauche-sdl/files/patch-src::image::sdl-image-lib.stub
new file mode 100644
index 000000000000..b1b64ae05cef
--- /dev/null
+++ b/devel/gauche-sdl/files/patch-src::image::sdl-image-lib.stub
@@ -0,0 +1,20 @@
+--- src/image/sdl-image-lib.stub.orig Mon Jan 2 04:11:06 2006
++++ src/image/sdl-image-lib.stub Mon Jan 2 04:11:38 2006
+@@ -61,7 +61,7 @@
+ (define-cproc img-load (file::<string>)
+ "ScmSdlSurface *s = SCM_NEW(ScmSdlSurface);
+ SCM_SET_CLASS(s, SCM_CLASS_SDL_SURFACE);
+- s->surface = IMG_Load((const char *)(SCM_STRING(file)->start));
++ s->surface = IMG_Load((const char *)(SCM_STRING_START(file)));
+
+ if (s->surface == NULL) SCM_RETURN(SCM_UNDEFINED);
+
+@@ -82,7 +82,7 @@
+ "ScmSdlSurface *s = SCM_NEW(ScmSdlSurface);
+ SCM_SET_CLASS(s, SCM_CLASS_SDL_SURFACE);
+ s->surface = IMG_LoadTyped_RW(src, 0,
+- (char *)(SCM_STRING(type)->start));
++ (char *)(SCM_STRING_START(type)));
+
+ if (s->surface == NULL) SCM_RETURN(SCM_UNDEFINED);
+
diff --git a/devel/gauche-sdl/files/patch-src::sdl-lib.stub b/devel/gauche-sdl/files/patch-src::sdl-lib.stub
new file mode 100644
index 000000000000..82948e84575b
--- /dev/null
+++ b/devel/gauche-sdl/files/patch-src::sdl-lib.stub
@@ -0,0 +1,60 @@
+--- src/sdl-lib.stub.orig Mon Feb 24 21:20:18 2003
++++ src/sdl-lib.stub Sat Dec 31 13:22:35 2005
+@@ -868,7 +868,7 @@
+ (define-cproc sdl-load-bmp (file::<string>)
+ "ScmSdlSurface *s = SCM_NEW(ScmSdlSurface);
+ SCM_SET_CLASS(s, SCM_CLASS_SDL_SURFACE);
+- s->surface = SDL_LoadBMP((const char *)(SCM_STRING(file)->start));
++ s->surface = SDL_LoadBMP((const char *)(SCM_STRING_START(file)));
+
+ if (s->surface == NULL) SCM_RETURN(SCM_UNDEFINED);
+
+@@ -876,7 +876,7 @@
+ SCM_RETURN(SCM_OBJ(s));")
+
+ (define-cproc sdl-save-bmp (surface::<sdl-surface> file::<string>)
+- "int result = SDL_SaveBMP(surface, (const char *)(SCM_STRING(file)->start));
++ "int result = SDL_SaveBMP(surface, (const char *)(SCM_STRING_START(file)));
+ SCM_RETURN(SCM_MAKE_INT(result));")
+
+ (define-cproc sdl-set-color-key (surface::<sdl-surface> flag::<uint> key::<uint>)
+@@ -950,7 +950,7 @@
+ (return <int> "SDL_ShowCursor"))
+
+ (define-cproc sdl-gl-load-library (path::<string>)
+- "int result = SDL_GL_LoadLibrary((const char *)(SCM_STRING(path)->start));
++ "int result = SDL_GL_LoadLibrary((const char *)(SCM_STRING_START(path)));
+ SCM_RETURN(SCM_MAKE_INT(result));")
+
+ ;; MISSING:
+@@ -1055,8 +1055,8 @@
+ ;;
+
+ (define-cproc sdl-wm-set-caption (title::<string> icon::<string>)
+- "SDL_WM_SetCaption((const char *)(SCM_STRING(title)->start),
+- (const char *)(SCM_STRING(icon)->start));
++ "SDL_WM_SetCaption((const char *)(SCM_STRING_START(title)),
++ (const char *)(SCM_STRING_START(icon)));
+ SCM_RETURN(SCM_UNDEFINED);")
+
+ (define-cproc sdl-wm-get-caption ()
+@@ -1269,7 +1269,7 @@
+ SCM_SET_CLASS(w, SCM_CLASS_SDL_WAV);
+ spec = &(SCM_SDL_WAV_SPEC(w));
+
+- spec = SDL_LoadWAV((const char *)(SCM_STRING(file)->start), spec, &buffer,
++ spec = SDL_LoadWAV((const char *)(SCM_STRING_START(file)), spec, &buffer,
+ &len);
+
+ SCM_SDL_WAV_BUFFER(w) = Scm_MakeU8VectorFromArrayShared(len, buffer);
+@@ -1384,8 +1384,8 @@
+ (define-cproc sdl-rw-from-file (file::<string> mode::<string>)
+ "ScmSdlRWops *rw = SCM_NEW(ScmSdlRWops);
+ SCM_SET_CLASS(rw, SCM_CLASS_SDL_RWOPS);
+- rw->rwops = SDL_RWFromFile((const char *)(SCM_STRING(file)->start),
+- (const char *)(SCM_STRING(mode)->start));
++ rw->rwops = SDL_RWFromFile((const char *)(SCM_STRING_START(file)),
++ (const char *)(SCM_STRING_START(mode)));
+
+ if (rw->rwops == NULL) SCM_RETURN(SCM_UNDEFINED);
+