On Thu, Dec 01, 2011 at 05:43:15PM -0500, Brad wrote:
> On Thu, Dec 01, 2011 at 05:43:12AM -0500, Brad wrote:
> > Here is a diff for the wxWidgets port to clean things up a bit, remove
> > some now unnecessary patches and enable the MediaCtrl class support.
> >
> > While taking a look over the port a bit more I noticed some disabled
> > bits utilizing the wide character functions which OpenBSD now has. So
> > enable that stuff.
> >
> > The socket fix was integrated a few releases ago. So eliminate the
> > redundant patch.
> >
> > Remove the NULL cast patch.
> >
> >
> > Tested on amd64. Everything in the ports tree utilizing wxWidgets
> > still builds Ok.
>
> Updated diff removing the contrib/src/Makefile.in patch update.
Looking at the autoconf patching I noticed the iodbc changes
can be simplified a bit. Here is an updated diff.
Index: Makefile
===================================================================
RCS file: /home/cvs/ports/x11/wxWidgets/Makefile,v
retrieving revision 1.36
diff -u -p -r1.36 Makefile
--- Makefile 16 Sep 2011 12:29:17 -0000 1.36
+++ Makefile 26 Nov 2011 11:14:38 -0000
@@ -2,12 +2,14 @@
SHARED_ONLY = Yes
-COMMENT = c++ cross-platform GUI toolkit
+COMMENT = C++ cross-platform GUI toolkit
V = 2.8.12
DISTNAME = wxWidgets-${V}
PKGNAME = wxWidgets-gtk2-${V}
-REVISION= 0
+REVISION = 1
+CATEGORIES = x11
+MASTER_SITES = ${MASTER_SITE_SOURCEFORGE:=wxwindows/}
SHARED_LIBS = wx_base 2.1 \
wx_base_net 2.1 \
@@ -22,6 +24,7 @@ SHARED_LIBS = wx_base 2.1 \
wx_gtk2_gizmos_xrc 2.1 \
wx_gtk2_gl 2.1 \
wx_gtk2_html 2.1 \
+ wx_gtk2_media 2.1 \
wx_gtk2_ogl 2.1 \
wx_gtk2_plot 2.1 \
wx_gtk2_qa 2.1 \
@@ -29,7 +32,6 @@ SHARED_LIBS = wx_base 2.1 \
wx_gtk2_stc 2.1 \
wx_gtk2_svg 2.1 \
wx_gtk2_xrc 2.1
-CATEGORIES = x11
HOMEPAGE = http://www.wxwidgets.org/
@@ -39,66 +41,49 @@ PERMIT_DISTFILES_FTP = Yes
PERMIT_PACKAGE_CDROM = Yes
PERMIT_PACKAGE_FTP = Yes
-MASTER_SITES = ${MASTER_SITE_SOURCEFORGE:=wxwindows/}
+WANTLIB += GL GLU SDL SM X11 Xcomposite Xcursor Xdamage Xext Xfixes
+WANTLIB += Xi Xinerama Xrandr Xrender Xxf86vm atk-1.0 c expat
+WANTLIB += fontconfig freetype gconf-2 gdk-x11-2.0 gdk_pixbuf-2.0
+WANTLIB += gio-2.0 glib-2.0 gmodule-2.0 gobject-2.0 gstinterfaces-0.10
+WANTLIB += gstreamer-0.10 gthread-2.0 gtk-x11-2.0 iodbc jpeg m
+WANTLIB += mspack pango-1.0 pangoft2-1.0 pixman-1 pthread pthread-stubs
+WANTLIB += stdc++ tiff xcb xcb-render xcb-shm xml2 z
MODULES = devel/gettext
-USE_GMAKE = Yes
-VMEM_WARNING = Yes
BUILD_DEPENDS = devel/cppunit
-
LIB_DEPENDS = archivers/libmspack \
+ databases/iodbc \
devel/sdl \
- x11/gtk+2 \
- databases/iodbc
+ multimedia/gstreamer-0.10/core \
+ multimedia/gstreamer-0.10/plugins-base \
+ x11/gtk+2
+REGRESS_DEPENDS = ${BUILD_PKGPATH}>=${V}
-REGRESS_DEPENDS +=${BUILD_PKGPATH}>=${V}
+VMEM_WARNING = Yes
-WANTLIB += GL GLU SM X11 Xau Xcomposite Xcursor Xdamage Xdmcp
-WANTLIB += Xext Xfixes Xi Xinerama Xrandr Xrender Xxf86vm atk-1.0
-WANTLIB += c drm expat fontconfig freetype gio-2.0 glib-2.0
-WANTLIB += gmodule-2.0 gobject-2.0 gthread-2.0 jpeg m pango-1.0
-WANTLIB += pangoft2-1.0 pixman-1 png pthread stdc++ SDL iodbc
-WANTLIB += tiff z pthread-stubs xcb xcb-render xcb-shm mspack
-WANTLIB += gdk-x11-2.0 gdk_pixbuf-2.0 gtk-x11-2.0
+MAKE_FLAGS = WXUNICODEFLAG=""
+.for _l _v in ${SHARED_LIBS}
+MAKE_ENV += LIB${_l}_VERSION=${_v}
+.endfor
+USE_GMAKE = Yes
AUTOCONF_VERSION = 2.59
-CONFIGURE_ENV = LDFLAGS="-L${LOCALBASE}/lib -L${X11BASE}/lib -pthread" \
- CPPFLAGS="-I${LOCALBASE}/include -I${LOCALBASE}/include/libpng
-I${X11BASE}/include" \
- ac_cv_lib_esd_esd_close=no \
- ac_cv_func_swprintf=no \
- wx_cv_func_wprintf=no \
- wx_cv_func_vswprintf=no
CONFIGURE_STYLE =autoconf no-autoheader
-CONFIGURE_ARGS =--with-expat=sys \
- --with-odbc=sys \
- --with-libjpeg=sys \
- --with-libpng=sys \
- --with-libtiff=sys \
- --with-libxpm=sys \
- --with-zlib=sys \
- --with-regex=builtin \
- --with-gtk \
+CONFIGURE_ARGS =--disable-backtrace \
+ --enable-mediactrl \
+ --enable-unicode \
+ --with-odbc \
--with-opengl \
--with-sdl \
- --without-gnomeprint \
- --without-gnomevfs \
- --without-hildon \
- --enable-gui \
- --enable-sound \
- --enable-unicode \
- --disable-backtrace \
- --disable-stl
+ --without-gnomeprint
+CONFIGURE_ENV = CPPFLAGS="-I${LOCALBASE}/include
-I${LOCALBASE}/include/libpng -I${X11BASE}/include" \
+ LDFLAGS="-L${LOCALBASE}/lib -L${X11BASE}/lib" \
+ ac_cv_lib_esd_esd_close=no
.ifdef DEBUG
CONFIGURE_ARGS += --enable-debug
.endif
-
-.for _l _v in ${SHARED_LIBS}
-MAKE_ENV += LIB${_l}_VERSION=${_v}
-.endfor
-
-MAKE_FLAGS = WXUNICODEFLAG=""
do-regress:
@cd ${WRKSRC}/tests && \
Index: patches/patch-configure_in
===================================================================
RCS file: /home/cvs/ports/x11/wxWidgets/patches/patch-configure_in,v
retrieving revision 1.7
diff -u -p -r1.7 patch-configure_in
--- patches/patch-configure_in 22 May 2011 08:13:18 -0000 1.7
+++ patches/patch-configure_in 2 Dec 2011 08:18:54 -0000
@@ -1,6 +1,6 @@
$OpenBSD: patch-configure_in,v 1.7 2011/05/22 08:13:18 dcoppa Exp $
---- configure.in.orig Tue Mar 22 12:59:37 2011
-+++ configure.in Wed May 18 10:53:09 2011
+--- configure.in.orig Tue Mar 22 07:59:37 2011
++++ configure.in Fri Dec 2 03:18:42 2011
@@ -3090,7 +3090,7 @@ if test "$wxUSE_LIBJPEG" != "no" ; then
dnl HAVE_STDLIB_H which are already defined and this provokes
dnl a compiler warning which configure considers as an error...
@@ -19,22 +19,23 @@ $OpenBSD: patch-configure_in,v 1.7 2011/
AC_MSG_RESULT($ac_cv_header_jpeglib_h)
if test "$ac_cv_header_jpeglib_h" = "yes"; then
-@@ -4154,13 +4154,7 @@ if test "$TOOLKIT" != "MSW" ; then
+@@ -4154,13 +4154,13 @@ if test "$TOOLKIT" != "MSW" ; then
AC_CHECK_HEADER([sql.h], [found_sql_h=1],, [ ])
if test "x$found_sql_h" = "x1" ; then
- AC_CHECK_LIB(iodbc, SQLAllocEnv, ODBC_LINK=" -liodbc",
-- [
-- AC_CHECK_LIB(unixodbc, SQLAllocEnv, ODBC_LINK=" -lunixodbc",
-- [
-- AC_CHECK_LIB(odbc, SQLAllocEnv, ODBC_LINK=" -lodbc")
-- ])
++ AC_CHECK_LIB(iodbc, SQLAllocEnv, ODBC_LINK=" -liodbc -pthread",
+ [
+ AC_CHECK_LIB(unixodbc, SQLAllocEnv, ODBC_LINK=" -lunixodbc",
+ [
+ AC_CHECK_LIB(odbc, SQLAllocEnv, ODBC_LINK=" -lodbc")
+ ])
- ])
-+ AC_CHECK_LIB(iodbc, SQLAllocEnv, ODBC_LINK="-pthread -liodbc")
++ ], [-pthread])
fi
if test "x$ODBC_LINK" = "x" ; then
if test "$wxUSE_ODBC" = "sys" ; then
-@@ -4480,7 +4474,7 @@ UNICODE=0
+@@ -4480,7 +4480,7 @@ UNICODE=0
lib_unicode_suffix=
WX_CHARTYPE="ansi"
if test "$wxUSE_UNICODE" = "yes"; then
@@ -43,7 +44,7 @@ $OpenBSD: patch-configure_in,v 1.7 2011/
WX_CHARTYPE="unicode"
UNICODE=1
fi
-@@ -4489,8 +4483,8 @@ lib_debug_suffix=
+@@ -4489,8 +4489,8 @@ lib_debug_suffix=
WX_DEBUGTYPE="release"
DEBUG_FLAG=0
if test "$wxUSE_DEBUG_FLAG" = "yes"; then
@@ -54,7 +55,7 @@ $OpenBSD: patch-configure_in,v 1.7 2011/
DEBUG_FLAG=1
fi
-@@ -4504,7 +4498,7 @@ fi
+@@ -4504,7 +4504,7 @@ fi
WX_VERSION_TAG=`echo
WX${lib_unicode_suffix}${lib_debug_suffix}${WX_LIB_FLAVOUR}_${WX_RELEASE} | tr
'[[a-z]]' '[[A-Z]]'`
@@ -63,18 +64,16 @@ $OpenBSD: patch-configure_in,v 1.7 2011/
TOOLCHAIN_FULLNAME="${TOOLKIT_DIR}${TOOLKIT_VERSION}${WIDGET_SET}-${WX_CHARTYPE}-${WX_DEBUGTYPE}${config_linkage_component}-${WX_RELEASE}${WX_FLAVOUR}"
-@@ -4730,14 +4724,6 @@ if test "$wxUSE_WCHAR_T" = "yes"; then
- if test "$USE_HPUX" = 1 -a "$GCC" != "yes"; then
- CPPFLAGS="-D_INCLUDE__STDC_A1_SOURCE $CPPFLAGS"
+@@ -5905,11 +5905,9 @@ else
+ dnl Switch on optimisation but keep strict-aliasing off for
+ dnl now (see -fstrict-aliasing in the gcc manual). When it is
+ dnl switched back on consider using -Wstrict-aliasing=2.
+- OPTIMISE_CFLAGS="-O2 -fno-strict-aliasing"
++ OPTIMISE_CFLAGS="-fno-strict-aliasing"
+ ;;
+ esac
+- else
+- OPTIMISE_CFLAGS="-O"
fi
--
-- dnl Try to use wcsrtombs instead of wcstombs which is buggy in old GNU
-- dnl libc versions if possible. AC_CHECK_FUNCS only checks it's in the
-- dnl library, not the header, so do a header check for mbstate_t first.
-- AC_CHECK_TYPES([mbstate_t],
-- [AC_CHECK_FUNCS(wcsrtombs)],
-- [],
-- [#include <wchar.h>])
- else
- AC_MSG_WARN([Wide character support is unavailable])
fi
+
Index: patches/patch-include_wx_wxchar_h
===================================================================
RCS file: patches/patch-include_wx_wxchar_h
diff -N patches/patch-include_wx_wxchar_h
--- patches/patch-include_wx_wxchar_h 22 May 2011 08:13:18 -0000 1.6
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,12 +0,0 @@
-$OpenBSD: patch-include_wx_wxchar_h,v 1.6 2011/05/22 08:13:18 dcoppa Exp $
---- include/wx/wxchar.h.orig Tue Mar 22 12:59:33 2011
-+++ include/wx/wxchar.h Wed May 18 10:52:50 2011
-@@ -474,6 +474,8 @@
- #endif
- #endif
-
-+ #define wxNEED_WX_MBSTOWCS
-+
- #ifdef wxNEED_WX_MBSTOWCS
- /* even though they are defined and "implemented", they are bad and
just
- stubs so we need our own - we need these even in ANSI builds!! */
Index: patches/patch-src_gtk_assertdlg_gtk_c
===================================================================
RCS file: patches/patch-src_gtk_assertdlg_gtk_c
diff -N patches/patch-src_gtk_assertdlg_gtk_c
--- patches/patch-src_gtk_assertdlg_gtk_c 2 Nov 2010 13:10:52 -0000
1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,21 +0,0 @@
-$OpenBSD: patch-src_gtk_assertdlg_gtk_c,v 1.1 2010/11/02 13:10:52 dcoppa Exp $
---- src/gtk/assertdlg_gtk.c.orig Wed Oct 27 16:02:54 2010
-+++ src/gtk/assertdlg_gtk.c Wed Oct 27 16:03:38 2010
-@@ -90,7 +90,7 @@ void gtk_assert_dialog_append_text_column (GtkWidget *
-
- renderer = gtk_cell_renderer_text_new ();
- column = gtk_tree_view_column_new_with_attributes (name, renderer,
-- "text", index, NULL);
-+ "text", index, (char
*)NULL);
- gtk_tree_view_insert_column (GTK_TREE_VIEW (treeview), column, index);
- gtk_tree_view_column_set_resizable (column, TRUE);
- gtk_tree_view_column_set_reorderable (column, TRUE);
-@@ -172,7 +172,7 @@ void gtk_assert_dialog_save_backtrace_callback (GtkWid
- GTK_FILE_CHOOSER_ACTION_SAVE,
- GTK_STOCK_CANCEL,
GTK_RESPONSE_CANCEL,
- GTK_STOCK_SAVE, GTK_RESPONSE_ACCEPT,
-- NULL);
-+ (char *)NULL);
-
- if (gtk_dialog_run (GTK_DIALOG (dialog)) == GTK_RESPONSE_ACCEPT)
- {
Index: patches/patch-src_unix_gsocket_cpp
===================================================================
RCS file: patches/patch-src_unix_gsocket_cpp
diff -N patches/patch-src_unix_gsocket_cpp
--- patches/patch-src_unix_gsocket_cpp 22 May 2011 08:13:18 -0000 1.3
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,18 +0,0 @@
-$OpenBSD: patch-src_unix_gsocket_cpp,v 1.3 2011/05/22 08:13:18 dcoppa Exp $
-
-The socket code in wxWidgets doesn't initialize the servent_data
-structure that is passed to getservbyname_r(). Programs that use this
-code die with a segfault. The attached patch zero-fills the buffer with
-memset().
-See upstream bugreport #10332.
-
---- src/unix/gsocket.cpp.orig Tue Mar 22 13:01:28 2011
-+++ src/unix/gsocket.cpp Wed May 18 10:52:51 2011
-@@ -2145,6 +2145,7 @@ GSocketError GAddress_INET_SetPortName(GAddress *addre
- char buffer[1024];
- #endif
- struct servent serv;
-+ memset(&buffer, 0, sizeof(buffer));
- se = wxGetservbyname_r(port, protocol, &serv,
- (void*)&buffer, sizeof(buffer));
- if (!se)
Index: pkg/PLIST
===================================================================
RCS file: /home/cvs/ports/x11/wxWidgets/pkg/PLIST,v
retrieving revision 1.9
diff -u -p -r1.9 PLIST
--- pkg/PLIST 28 Apr 2011 17:50:43 -0000 1.9
+++ pkg/PLIST 26 Nov 2011 09:48:47 -0000
@@ -634,6 +634,7 @@ include/wx/zstream.h
@lib lib/libwx_gtk2_gizmos_xrc.so.${LIBwx_gtk2_gizmos_xrc_VERSION}
@lib lib/libwx_gtk2_gl.so.${LIBwx_gtk2_gl_VERSION}
@lib lib/libwx_gtk2_html.so.${LIBwx_gtk2_html_VERSION}
+@lib lib/libwx_gtk2_media.so.${LIBwx_gtk2_media_VERSION}
@lib lib/libwx_gtk2_ogl.so.${LIBwx_gtk2_ogl_VERSION}
@lib lib/libwx_gtk2_plot.so.${LIBwx_gtk2_plot_VERSION}
@lib lib/libwx_gtk2_qa.so.${LIBwx_gtk2_qa_VERSION}
--
This message has been scanned for viruses and
dangerous content by MailScanner, and is
believed to be clean.