Bug 123708 - [MAINTAINER] graphics/gnash: update to 0.8.2
Summary: [MAINTAINER] graphics/gnash: update to 0.8.2
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Martin Wilke
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-05-15 17:50 UTC by Dmitry Marakasov
Modified: 2008-05-24 20:00 UTC (History)
0 users

See Also:


Attachments
gnash-0.8.2.patch (12.66 KB, patch)
2008-05-15 17:50 UTC, Dmitry Marakasov
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Marakasov 2008-05-15 17:50:03 UTC
Sorry for a long delay, here is it finally: update Gnash to 0.8.2.

ports/123349 and ports/123379 may be closed.

Also please note that OpenGL support in this release is broken (Gnash nearly hangs the whole system with (seems like) tons of mallocs).

I'm also considering adding gnash-devel port based on latest CVS snapshot depending on whether it behaves better.

Additional thanks to Carlos Santos and Craig Rodrigues for their PRs from which I've used some bits.

Some notes on Carlos' changes:

> 2. Add the dependency on libltdl15.
Not needed, see USE_AUTOTOOLS

> 4. Add one configuration option, "NLS"
Will be added when it actually works

> 7. Add a trick to get the "render_handler_ogl.h"
Just added it as a patch. no need for cvs magic

> MAN1+=         cygnal.1
This man is installed regardless on whether cygnal is built
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2008-05-15 17:50:10 UTC
Responsible Changed
From-To: freebsd-ports-bugs->miwi

miwi@ wants his PRs (via the GNATS Auto Assign Tool)
Comment 2 Dmitry Marakasov 2008-05-17 00:49:07 UTC
* FreeBSD-gnats-submit@FreeBSD.org (FreeBSD-gnats-submit@FreeBSD.org) wrote:

> http://www.freebsd.org/cgi/query-pr.cgi?pr=123708

Plese use this updated patch. Fixes some issues and adds conflicts with
upcoming gnash-devel

--- gnash.patch begins here ---
diff -ruN gnash.orig/Makefile gnash/Makefile
--- gnash.orig/Makefile	2008-05-17 03:45:37.855114795 +0400
+++ gnash/Makefile	2008-05-17 03:27:45.215909533 +0400
@@ -2,12 +2,11 @@
 # Date created:				12 Jan 2006
 # Whom:					Dmitry Marakasov <amdmi3@amdmi3.ru>
 #
-# $FreeBSD: ports/graphics/gnash/Makefile,v 1.23 2008/04/19 17:50:10 miwi Exp $
+# $FreeBSD: ports/graphics/gnash/Makefile,v 1.21 2008/03/13 14:28:22 miwi Exp $
 #
 
 PORTNAME=	gnash
-PORTVERSION=	0.8.1
-PORTREVISION=	3
+PORTVERSION=	0.8.2
 CATEGORIES=	graphics
 MASTER_SITES=	${MASTER_SITE_GNU}
 MASTER_SITE_SUBDIR=	${PORTNAME}/${PORTVERSION}
@@ -19,6 +18,8 @@
 		jpeg.9:${PORTSDIR}/graphics/jpeg \
 		curl.4:${PORTSDIR}/ftp/curl
 
+CONFLICTS=	gnash-devel-[0-9]*
+
 USE_BZIP2=	yes
 USE_GMAKE=	yes
 GNU_CONFIGURE=	yes
@@ -26,10 +27,9 @@
 WANT_GNOME=	yes
 WANT_GSTREAMER=	yes
 USE_GNOME=	pkgconfig libxml2
+USE_XORG=	x11 xau xdmcp xext xi xinerama ice sm
 USE_AUTOTOOLS=	libltdl:15
 
-PLUGIN_DIR=	${PREFIX}/lib/browser_plugins
-
 CONFIGURE_TARGET=	--build=${MACHINE_ARCH}-portbld-freebsd${OSREL}
 CONFIGURE_ENV=	CPPFLAGS="-I${LOCALBASE}/include" \
 		LDFLAGS="-L${LOCALBASE}/lib" \
@@ -37,23 +37,22 @@
 		PTHREAD_CFLAGS="${PTHREAD_CFLAGS} ${PTHREAD_LIBS}"
 CONFIGURE_ARGS=	--with-boost-incl="${LOCALBASE}/include" \
 		--with-boost-lib="${LOCALBASE}/lib" \
-		--with-plugindir="${PLUGIN_DIR}"
+		--with-npapi-plugindir="${PREFIX}/lib/browser_plugins" \
+		--with-kde-pluginprefix="${PREFIX}"
 
 USE_LDCONFIG=	${PREFIX}/lib/gnash
 
-MAN1=		gnash.1
+MAN1=		cygnal.1 gnash.1 gprocessor.1 soldumper.1 dumpshm.1
 
 OPTIONS=	PLUGIN		"Enable browser plugin" on \
 		CYGNAL		"Enable Cygnal media server" off \
-		GTK		"GUI: GTK (required for FF plugin)" on \
+		GTK		"GUI: GTK (required for Mozilla/Firefox plugin)" on \
 		KDE		"GUI: KDE (required for Konqueror plugin)" off \
 		AGG		"Renderer: AGG" on \
-		OPENGL		"Renderer: OpenGL" off \
+		OPENGL		"Renderer: OpenGL (broken)" off \
 		CAIRO		"Renderer: Cairo (experimental)" off \
 		FFMPEG		"Media handler: ffmpeg (+SDL sound output)" on \
-		GSTREAMER	"Media handler: GStreamer" off \
-		MAD		"Media handler: MAD (+SDL sound output)" off  \
-		DEBUGLOG	"Leave logfile in current directory on every run" off
+		GSTREAMER	"Media handler: GStreamer" off
 
 .include <bsd.port.pre.mk>
 
@@ -67,6 +66,7 @@
 
 .if defined(WITH_KDE) && !defined(WITHOUT_PLUGIN)
 PLIST_SUB+=	KONQPLUGIN=""
+USE_LDCONFIG+=	${PREFIX}/lib/kde3
 .else
 PLIST_SUB+=	KONQPLUGIN="@comment "
 CONFIGURE_ARGS+=	--disable-kparts
@@ -111,12 +111,14 @@
 # 5.5/6.2 EOL. We could also include bsd.kde.mk here, but that's much more
 # likely to bring more trouble
 LIB_DEPENDS+=	kimproxy:${PORTSDIR}/x11/kdelibs3
-CONFIGURE_ARGS+=--with-qt-incl="${LOCALBASE}/include" \
-		--with-qt-lib="${LOCALBASE}/lib"
 .else
 PLIST_SUB+=	KDE="@comment "
 .endif
 
+.if ${GNASH_GUIS} == ""
+IGNORE=		needs at least one GUI enabled. Please rerun 'make config' and enable GTK, KDE or both GUIs
+.endif
+
 CONFIGURE_ARGS+=	--enable-gui=`${ECHO} ${GNASH_GUIS} | ${TR} ' ' ,`
 
 #
@@ -144,32 +146,43 @@
 #
 # Media handler options processing
 #
-.if defined(WITH_FFMPEG) && !defined(WITH_GSTREAMER) && !defined(WITH_MAD)
+.if defined(WITH_FFMPEG) && !defined(WITH_GSTREAMER)
 LIB_DEPENDS+=		avcodec.1:${PORTSDIR}/multimedia/ffmpeg
 CONFIGURE_ARGS+=	--enable-media=ffmpeg
 USE_SDL+=		sdl
-.elif !defined(WITH_FFMPEG) && defined(WITH_GSTREAMER) && !defined(WITH_MAD)
+.elif !defined(WITH_FFMPEG) && defined(WITH_GSTREAMER)
 USE_GSTREAMER=		yes
 CONFIGURE_ARGS+=	--enable-media=gst
-.elif !defined(WITH_FFMPEG) && !defined(WITH_GSTREAMER) && defined(WITH_MAD)
-LIB_DEPENDS+=		mad.2:${PORTSDIR}/audio/libmad
-CONFIGURE_ARGS+=	--enable-media=mad
-USE_SDL+=		sdl
-.elif !defined(WITH_FFMPEG) && !defined(WITH_GSTREAMER) && !defined(WITH_MAD)
+.elif !defined(WITH_FFMPEG) && !defined(WITH_GSTREAMER)
 CONFIGURE_ARGS+=	--enable-media=none
 .else
-IGNORE=			can't be built with multiple media handlers enabled. Please rerun 'make config' and leave one or none of them (ffmpeg|gstreamer|mad)
+IGNORE=			can't be built with multiple media handlers enabled. Please rerun 'make config' and leave one or none of them (ffmpeg|gstreamer)
+.endif
+
+pre-everything::
+.if defined(WITH_OPENGL)
+	@${ECHO_CMD} "OpenGL support is currently broken (Gnash hangs using 100% CPU). Use at your own risk"
+	@sleep 3
 .endif
 
 post-patch:
-	@${REINPLACE_CMD} -e '/^PTHREAD_[A-Z]*=/ d' ${WRKSRC}/configure
-	@${REINPLACE_CMD} -e '/test/ s|==|=|; s|== x|= x|' ${WRKSRC}/configure
+	@${REINPLACE_CMD} -e 's|^LIBS = |&$${INTLLIBS} |' \
+		${WRKSRC}/utilities/Makefile.in ${WRKSRC}/cygnal/Makefile.in
+	@${REINPLACE_CMD} -e '/^PTHREAD_[LC][IF]*=/ d' ${WRKSRC}/configure
 	@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|g; \
 		s|/usr/X11R6|${LOCALBASE}|g' ${WRKSRC}/configure \
 		${WRKSRC}/macros/libslist ${WRKSRC}/macros/incllist
-.if !defined(WITH_DEBUGLOG)
-	@${REINPLACE_CMD} -e 's|gnash-dbg.log|/dev/null|' \
-		${WRKSRC}/libbase/rc.cpp ${WRKSRC}/libbase/log.h
+
+.if !defined(WITHOUT_PLUGIN)
+post-install:
+.if defined(WITH_GTK)
+	@cd ${INSTALL_WRKSRC}/plugin && \
+		${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_ARGS} install-plugin
+.endif
+.if defined(WITH_KDE)
+	@cd ${INSTALL_WRKSRC}/plugin/klash && \
+		${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_ARGS} install-plugin
+.endif
 .endif
 
 .include <bsd.port.post.mk>
diff -ruN gnash.orig/distinfo gnash/distinfo
--- gnash.orig/distinfo	2008-05-17 03:45:37.857186008 +0400
+++ gnash/distinfo	2008-05-15 03:27:13.243043436 +0400
@@ -1,3 +1,3 @@
-MD5 (gnash-0.8.1.tar.bz2) = 5f80a25cb7a37fb351d28fd2097d8f3e
-SHA256 (gnash-0.8.1.tar.bz2) = 30fb283e707bc209109ca313c83b069b1c482497b62f8c4cc37e9a23e0ba8993
-SIZE (gnash-0.8.1.tar.bz2) = 1983596
+MD5 (gnash-0.8.2.tar.bz2) = 05cac831181be3fb40cbf3c00ab25c0f
+SHA256 (gnash-0.8.2.tar.bz2) = 4c81e71e6619b79da9641a90ed2c73c362603103bcdcc7b9cc5cc53739d06baa
+SIZE (gnash-0.8.2.tar.bz2) = 2637636
diff -ruN gnash.orig/files/patch-backend-render_handler_ogl.h gnash/files/patch-backend-render_handler_ogl.h
--- gnash.orig/files/patch-backend-render_handler_ogl.h	1970-01-01 03:00:00.000000000 +0300
+++ gnash/files/patch-backend-render_handler_ogl.h	2008-05-15 06:19:57.307793285 +0400
@@ -0,0 +1,178 @@
+diff -ruN backend/render_handler_ogl.h.orig backend/render_handler_ogl.h
+--- backend/render_handler_ogl.h.orig	1970-01-01 03:00:00.000000000 +0300
++++ backend/render_handler_ogl.h	2008-05-15 06:18:41.725653935 +0400
+@@ -0,0 +1,174 @@
++// 
++//   Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc.
++// 
++// This program is free software; you can redistribute it and/or modify
++// it under the terms of the GNU General Public License as published by
++// the Free Software Foundation; either version 3 of the License, or
++// (at your option) any later version.
++// 
++// This program is distributed in the hope that it will be useful,
++// but WITHOUT ANY WARRANTY; without even the implied warranty of
++// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
++// GNU General Public License for more details.
++// 
++// You should have received a copy of the GNU General Public License
++// along with this program; if not, write to the Free Software
++// Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301 USA
++
++#ifndef __RENDER_HANDLER_OGL_H__
++#define __RENDER_HANDLER_OGL_H__
++
++
++#if defined(NOT_SGI_GL) || defined(__APPLE_CC__)
++#include <AGL/agl.h>
++#include <OpenGL/gl.h>
++#include <OpenGL/glu.h>
++#include <OpenGL/glext.h>
++#define GLUCALLBACKTYPE GLvoid (*)(...)
++#else
++# define GLUCALLBACKTYPE void (*)()
++# include <GL/gl.h>
++# ifdef WIN32
++#  define GL_CLAMP_TO_EDGE 0x812F
++# else
++# include <GL/glx.h>
++# ifdef OSMESA_TESTING
++#  include <GL/osmesa.h>
++# endif // OSMESA_TESTING
++# endif
++# include <GL/glu.h>
++# ifndef APIENTRY
++#  define APIENTRY
++# endif
++#endif
++
++
++
++
++namespace gnash {
++
++
++
++
++typedef std::vector<const path*> PathRefs;
++
++
++
++struct oglVertex {
++  oglVertex(double x, double y, double z = 0.0)
++    : _x(x), _y(y), _z(z)
++  {
++  }
++  
++  oglVertex(const point& p)
++    : _x(p.x), _y(p.y), _z(0.0)
++  {
++  }
++
++  GLdouble _x;
++  GLdouble _y;
++  GLdouble _z;
++};
++
++typedef std::map< const path*, std::vector<oglVertex> > PathPointMap;
++
++class Tesselator
++{
++public:
++  Tesselator();  
++  ~Tesselator();
++  
++  void beginPolygon();
++  
++  void feed(std::vector<oglVertex>& vertices);
++  
++  void tesselate();
++  
++  void beginContour();
++  void endContour();
++  
++  void rememberVertex(GLdouble* v);
++  
++  static void
++  error(GLenum error);
++
++  static void combine(GLdouble coords [3], void *vertex_data[4],
++                      GLfloat weight[4], void **outData, void* userdata);
++  
++
++  
++private:
++  std::vector<GLdouble*> _vertices;
++  GLUtesselator* _tessobj;
++};
++
++class WholeShape
++{
++public:
++  void newPath(const path& new_path)
++  {
++    PathRefs refs;
++    refs.push_back(&new_path);
++    
++    shape.push_back(refs);
++  }
++  
++  void addPath(const path& add_path)
++  {
++    PathRefs& refs = shape.back();
++    refs.push_back(&add_path);
++  }
++  
++  void addPathRefs(const PathRefs& pathrefs)
++  {
++  
++    PathRefs new_refs(pathrefs.begin(), pathrefs.end());
++    
++    shape.push_back(new_refs);
++  }
++  
++  
++  const std::vector<PathRefs>& get() const
++  {
++    return shape;
++  }
++  
++private:
++  std::vector<PathRefs> shape;
++
++};
++
++
++class bitmap_info_ogl : public bitmap_info
++{
++  public:
++    bitmap_info_ogl(image::image_base* image, GLenum pixelformat,
++                    bool ogl_accessible);
++    ~bitmap_info_ogl();
++
++    void apply(const gnash::matrix& bitmap_matrix,
++               render_handler::bitmap_wrap_mode wrap_mode);
++  private:
++    inline bool ogl_accessible() const;
++    void setup();    
++    void upload(boost::uint8_t* data, size_t width, size_t height);
++    
++    std::auto_ptr<image::image_base> _img;
++    GLenum _pixel_format;
++    GLenum _ogl_img_type;
++    bool _ogl_accessible;  
++    GLuint _texture_id;
++    size_t _orig_width;
++    size_t _orig_height;
++};
++
++
++
++
++
++
++} // namespace gnash
++
++
++#endif // __RENDER_HANDLER_OGL_H__
++
diff -ruN gnash.orig/files/patch-utilities-Makefile.in gnash/files/patch-utilities-Makefile.in
--- gnash.orig/files/patch-utilities-Makefile.in	2008-05-17 03:45:37.814535056 +0400
+++ gnash/files/patch-utilities-Makefile.in	1970-01-01 03:00:00.000000000 +0300
@@ -1,11 +0,0 @@
---- utilities/Makefile.in.orig	2007-08-29 15:03:59.000000000 +0000
-+++ utilities/Makefile.in	2007-11-07 20:37:02.000000000 +0000
-@@ -365,7 +365,7 @@
- 	$(top_builddir)/libbase/libgnashbase.la \
- 	$(top_builddir)/backend/libgnashbackend.la \
- 	$(top_builddir)/libamf/libgnashamf.la $(am__append_2) \
--	$(am__append_4) $(GLIB_LIBS) $(GSTREAMER_LIBS)
-+	$(am__append_4) $(GLIB_LIBS) $(GSTREAMER_LIBS) $(INTLLIBS)
- AM_LDFLAGS = \
- 	$(LIBADD_DL) \
- 	$(LIBLTDL) \
diff -ruN gnash.orig/pkg-plist gnash/pkg-plist
--- gnash.orig/pkg-plist	2008-05-17 03:45:37.837426234 +0400
+++ gnash/pkg-plist	2008-05-15 20:04:13.260790661 +0400
@@ -1,43 +1,49 @@
+bin/dumpshm
 bin/gnash
-bin/gparser
 bin/gprocessor
+bin/soldumper
 %%GTK%%bin/gtk-gnash
 %%KDE%%bin/kde-gnash
 %%CYGNAL%%bin/cygnal
 %%FFPLUGIN%%lib/browser_plugins/libgnashplugin.so
-%%KONQPLUGIN%%lib/kde3/libklashpart.so
+%%KONQPLUGIN%%share/apps/klash/pluginsinfo
+%%KONQPLUGIN%%share/apps/klash/klashpartui.rc
+%%KONQPLUGIN%%share/services/klash_part.desktop
 %%KONQPLUGIN%%lib/kde3/libklashpart.a
+%%KONQPLUGIN%%lib/kde3/libklashpart.so
 %%KONQPLUGIN%%lib/kde3/libklashpart.la
-lib/gnash/libgnashamf-0.8.1.so
+lib/gnash/libgnashamf-0.8.2.so
 lib/gnash/libgnashamf.a
 lib/gnash/libgnashamf.la
 lib/gnash/libgnashamf.so
-lib/gnash/libgnashbackend-0.8.1.so
-lib/gnash/libgnashbackend.a
-lib/gnash/libgnashbackend.la
-lib/gnash/libgnashbackend.so
-lib/gnash/libgnashbase-0.8.1.so
+lib/gnash/libgnashbase-0.8.2.so
 lib/gnash/libgnashbase.a
 lib/gnash/libgnashbase.la
 lib/gnash/libgnashbase.so
-lib/gnash/libgnashgeo-0.8.1.so
-lib/gnash/libgnashgeo.a
-lib/gnash/libgnashgeo.la
-lib/gnash/libgnashgeo.so
-lib/gnash/libgnashserver-0.8.1.so
+lib/gnash/libgnashmedia-0.8.2.so
+lib/gnash/libgnashmedia.a
+lib/gnash/libgnashmedia.la
+lib/gnash/libgnashmedia.so
+lib/gnash/libgnashserver-0.8.2.so
 lib/gnash/libgnashserver.a
 lib/gnash/libgnashserver.la
 lib/gnash/libgnashserver.so
+%%DOCSDIR%%/gnashuser.html
+%%DOCSDIR%%/images/car_crash.png
+%%DOCSDIR%%/images/rtmp.png
+%%DOCSDIR%%/gnashref.html
 %%DATADIR%%/GnashG.png
 %%DATADIR%%/gnash_128_96.ico
-%%KONQPLUGIN%%share/apps/klash/pluginsinfo
-%%KONQPLUGIN%%share/apps/klash/klashpartui.rc
-%%KONQPLUGIN%%share/services/klash_part.desktop
-share/locale/cs/gnash.mo
-share/locale/de/gnash.mo
-share/locale/es/gnash.mo
-share/locale/fr/gnash.mo
-share/locale/it/gnash.mo
+share/locale/cs/LC_MESSAGES/gnash.mo
+share/locale/de/LC_MESSAGES/gnash.mo
+share/locale/es/LC_MESSAGES/gnash.mo
+share/locale/fi/LC_MESSAGES/gnash.mo
+share/locale/fr/LC_MESSAGES/gnash.mo
+share/locale/it/LC_MESSAGES/gnash.mo
+share/locale/sv/LC_MESSAGES/gnash.mo
 @dirrm %%DATADIR%%
+@dirrm %%DOCSDIR%%/images
+@dirrm %%DOCSDIR%%
 @dirrm lib/gnash
-@dirrmtry lib/browser_plugins
+%%KONQPLUGIN%%@dirrm share/apps/klash
+%%FFPLUGIN%%@dirrmtry lib/browser_plugins
--- gnash.patch ends here ---

-- 
Dmitry A. Marakasov    | jabber: amdmi3@jabber.ru
amdmi3@amdmi3.ru       | http://www.amdmi3.ru
Comment 3 dfilter service freebsd_committer freebsd_triage 2008-05-24 19:57:18 UTC
miwi        2008-05-24 18:57:14 UTC

  FreeBSD ports repository

  Modified files:
    graphics/gnash       Makefile distinfo pkg-plist 
  Added files:
    graphics/gnash/files patch-backend-render_handler_ogl.h 
  Removed files:
    graphics/gnash/files patch-utilities-Makefile.in 
  Log:
  - Update to 0.8.2
  
  PR:             123708
  Submitted by:   Dmitry Marakasov <amdmi3@amdmi3.ru> (maintainer)
  
  Revision  Changes    Path
  1.24      +39 -26    ports/graphics/gnash/Makefile
  1.6       +3 -3      ports/graphics/gnash/distinfo
  1.1       +178 -0    ports/graphics/gnash/files/patch-backend-render_handler_ogl.h (new)
  1.2       +0 -11     ports/graphics/gnash/files/patch-utilities-Makefile.in (dead)
  1.7       +28 -22    ports/graphics/gnash/pkg-plist
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 4 Martin Wilke freebsd_committer freebsd_triage 2008-05-24 19:57:22 UTC
State Changed
From-To: open->closed

Committed. Thanks!