Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/audio/buzztrax buzztrax: attempt to fix build



details:   https://anonhg.NetBSD.org/pkgsrc/rev/0d61f7040425
branches:  trunk
changeset: 434825:0d61f7040425
user:      nia <nia%pkgsrc.org@localhost>
date:      Mon Jun 22 11:18:38 2020 +0000

description:
buzztrax: attempt to fix build

diffstat:

 audio/buzztrax/Makefile                                      |   17 +-
 audio/buzztrax/PLIST                                         |   33 +--
 audio/buzztrax/distinfo                                      |    4 +-
 audio/buzztrax/patches/patch-src_gst_fluidsynth_fluidsynth.c |  169 +++++++++++
 audio/buzztrax/patches/patch-src_gst_fluidsynth_fluidsynth.h |   14 +
 5 files changed, 197 insertions(+), 40 deletions(-)

diffs (truncated from 319 to 300 lines):

diff -r edd4cc4bf53f -r 0d61f7040425 audio/buzztrax/Makefile
--- a/audio/buzztrax/Makefile   Mon Jun 22 11:13:18 2020 +0000
+++ b/audio/buzztrax/Makefile   Mon Jun 22 11:18:38 2020 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.11 2020/06/02 08:23:08 adam Exp $
+# $NetBSD: Makefile,v 1.12 2020/06/22 11:18:38 nia Exp $
 
 DISTNAME=      buzztrax-0.10.2
-PKGREVISION=   3
+PKGREVISION=   4
 CATEGORIES=    audio
 MASTER_SITES=  https://files.buzztrax.org/releases/
 
@@ -11,7 +11,6 @@
 LICENSE=       gnu-lgpl-v2.1
 
 TOOL_DEPENDS+= libxslt-[0-9]*:../../textproc/libxslt
-DEPENDS+=      gsettings-desktop-schemas-[0-9]*:../../sysutils/gsettings-desktop-schemas
 
 CONFLICTS+=    buzztard-[0-9]*
 SUPERSEDES+=   buzztard-[0-9]*
@@ -24,18 +23,20 @@
 USE_TOOLS+=    msgfmt msgmerge xgettext
 USE_TOOLS+=    gmake
 
-# GLib-GIO-ERROR **: Settings schema 'org.buzztrax' is not installed
-MAKE_ENV+=     GCONF_DISABLE_MAKEFILE_SCHEMA_INSTALL=1
-
 PLIST_SRC=     ${PLIST_SRC_DFLT}
 
 USE_PKGLOCALEDIR=      yes
 
+CONFIGURE_ENV+=                ac_cv_path_scrollkeeper_config=no
+CONFIGURE_ENV+=                ac_cv_path_xvfb_path=no
+
 CONFIGURE_ARGS+=       --disable-dllwrapper
-CONFIGURE_ARGS+=       --disable-schemas-compile
 
 .include "options.mk"
 .include "../../devel/glib2/schemas.mk"
+.include "../../audio/fluidsynth/buildlink3.mk"
+.include "../../devel/gettext-lib/buildlink3.mk"
+.include "../../devel/libgsf/buildlink3.mk"
 .include "../../graphics/clutter-gtk/buildlink3.mk"
 .include "../../graphics/gnome-icon-theme/buildlink3.mk"
 .include "../../graphics/hicolor-icon-theme/buildlink3.mk"
@@ -43,7 +44,7 @@
 .include "../../multimedia/gst-plugins1-base/buildlink3.mk"
 .include "../../textproc/aspell/buildlink3.mk"
 .include "../../textproc/libxml2/buildlink3.mk"
-.include "../../textproc/rarian/buildlink3.mk"
 .include "../../sysutils/desktop-file-utils/desktopdb.mk"
+.include "../../sysutils/gsettings-desktop-schemas/buildlink3.mk"
 .include "../../x11/gtk3/buildlink3.mk"
 .include "../../mk/bsd.pkg.mk"
diff -r edd4cc4bf53f -r 0d61f7040425 audio/buzztrax/PLIST
--- a/audio/buzztrax/PLIST      Mon Jun 22 11:13:18 2020 +0000
+++ b/audio/buzztrax/PLIST      Mon Jun 22 11:18:38 2020 +0000
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.1 2019/10/16 11:18:11 nia Exp $
+@comment $NetBSD: PLIST,v 1.2 2020/06/22 11:18:38 nia Exp $
 bin/buzztrax-cmd
 bin/buzztrax-edit
 include/libbml/BuzzMachineLoader.h
@@ -62,6 +62,7 @@
 lib/gstreamer-1.0/libbuzztraxaudio.la
 lib/gstreamer-1.0/libbuzztraxdec.la
 lib/gstreamer-1.0/libgstbml.la
+lib/gstreamer-1.0/libgstfluidsynth.la
 lib/gstreamer-1.0/libgstsidsyn.la
 lib/libbml.la
 lib/libbuzztrax-core.la
@@ -103,35 +104,6 @@
 share/buzztrax/songs/melo5.xml
 share/buzztrax/songs/melo6.xml
 share/glib-2.0/schemas/org.buzztrax.gschema.xml
-share/gnome/help/buzztrax-edit/C/buzztrax-edit.xml
-share/gnome/help/buzztrax-edit/C/figures/about.png
-share/gnome/help/buzztrax-edit/C/figures/crash-recovery.png
-share/gnome/help/buzztrax-edit/C/figures/interaction-controller-learn.png
-share/gnome/help/buzztrax-edit/C/figures/machine-preferences.png
-share/gnome/help/buzztrax-edit/C/figures/machine-properties.png
-share/gnome/help/buzztrax-edit/C/figures/machine-rename.png
-share/gnome/help/buzztrax-edit/C/figures/main-window.png
-share/gnome/help/buzztrax-edit/C/figures/missing-gstreamer-elements.png
-share/gnome/help/buzztrax-edit/C/figures/missing-song-elements.png
-share/gnome/help/buzztrax-edit/C/figures/page-info-view.png
-share/gnome/help/buzztrax-edit/C/figures/page-machine-view.png
-share/gnome/help/buzztrax-edit/C/figures/page-pattern-view.png
-share/gnome/help/buzztrax-edit/C/figures/page-sequence-view.png
-share/gnome/help/buzztrax-edit/C/figures/page-wavetable-view.png
-share/gnome/help/buzztrax-edit/C/figures/pattern-properties.png
-share/gnome/help/buzztrax-edit/C/figures/preset-properties.png
-share/gnome/help/buzztrax-edit/C/figures/recording-progress.png
-share/gnome/help/buzztrax-edit/C/figures/recording-settings.png
-share/gnome/help/buzztrax-edit/C/figures/settings-audio.png
-share/gnome/help/buzztrax-edit/C/figures/settings-colors.png
-share/gnome/help/buzztrax-edit/C/figures/settings-directories.png
-share/gnome/help/buzztrax-edit/C/figures/settings-ic.png
-share/gnome/help/buzztrax-edit/C/figures/settings-pc.png
-share/gnome/help/buzztrax-edit/C/figures/settings-shortcuts.png
-share/gnome/help/buzztrax-edit/C/figures/signal-analysis.png
-share/gnome/help/buzztrax-edit/C/figures/tip.png
-share/gnome/help/buzztrax-edit/C/legal.xml
-share/gnome/help/buzztrax-edit/C/version.entities
 share/gstreamer-1.0/presets/GstBtEBeats.prs
 share/gstreamer-1.0/presets/GstBtSimSyn.prs
 share/gtk-doc/html/buzztrax-cmd/BtCmdApplication.html
@@ -494,4 +466,3 @@
 share/locale/zh_CN/LC_MESSAGES/${PKGNAME}.mo
 share/mime/packages/buzztrax-songio-buzz.xml
 share/mime/packages/buzztrax.xml
-share/omf/buzztrax-edit/buzztrax-edit-C.omf
diff -r edd4cc4bf53f -r 0d61f7040425 audio/buzztrax/distinfo
--- a/audio/buzztrax/distinfo   Mon Jun 22 11:13:18 2020 +0000
+++ b/audio/buzztrax/distinfo   Mon Jun 22 11:18:38 2020 +0000
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.1 2019/10/16 11:18:11 nia Exp $
+$NetBSD: distinfo,v 1.2 2020/06/22 11:18:38 nia Exp $
 
 SHA1 (buzztrax-0.10.2.tar.gz) = ee70b76eeea42445e7172a2d2dd2d86051428fa6
 RMD160 (buzztrax-0.10.2.tar.gz) = ff03dc597bf77a78afd2656488e7e598d159a7d4
@@ -6,3 +6,5 @@
 Size (buzztrax-0.10.2.tar.gz) = 4121943 bytes
 SHA1 (patch-configure) = 6e5e6efaa6f4847b1a5648f18343ee546fbca065
 SHA1 (patch-src_gst_dec_bt-dec.c) = ee651defd4ff51622786b13d35cf783c9986386e
+SHA1 (patch-src_gst_fluidsynth_fluidsynth.c) = 98d7fb9ac418673656b04df14907da5585d30d95
+SHA1 (patch-src_gst_fluidsynth_fluidsynth.h) = b037bdce46dad8c5b75ee5c8f17da73be645e141
diff -r edd4cc4bf53f -r 0d61f7040425 audio/buzztrax/patches/patch-src_gst_fluidsynth_fluidsynth.c
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/audio/buzztrax/patches/patch-src_gst_fluidsynth_fluidsynth.c      Mon Jun 22 11:18:38 2020 +0000
@@ -0,0 +1,169 @@
+$NetBSD: patch-src_gst_fluidsynth_fluidsynth.c,v 1.1 2020/06/22 11:18:39 nia Exp $
+
+Fix build with fluidsynth 2.x. From Debian.
+
+--- src/gst/fluidsynth/fluidsynth.c.orig       2015-12-29 21:24:20.000000000 +0000
++++ src/gst/fluidsynth/fluidsynth.c
+@@ -132,25 +132,41 @@ G_DEFINE_TYPE (GstBtFluidSynth, gstbt_fl
+ //-- fluid_synth log handler
+ 
+ static void
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+ gstbt_fluid_synth_error_log_function (int level, char *message, void *data)
++#else
++gstbt_fluid_synth_error_log_function (int level, const char *message, void *data)
++#endif
+ {
+   GST_ERROR ("%s", message);
+ }
+ 
+ static void
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+ gstbt_fluid_synth_warning_log_function (int level, char *message, void *data)
++#else
++gstbt_fluid_synth_warning_log_function (int level, const char *message, void *data)
++#endif
+ {
+   GST_WARNING ("%s", message);
+ }
+ 
+ static void
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+ gstbt_fluid_synth_info_log_function (int level, char *message, void *data)
++#else
++gstbt_fluid_synth_info_log_function (int level, const char *message, void *data)
++#endif
+ {
+   GST_INFO ("%s", message);
+ }
+ 
+ static void
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+ gstbt_fluid_synth_debug_log_function (int level, char *message, void *data)
++#else
++gstbt_fluid_synth_debug_log_function (int level, const char *message, void *data)
++#endif
+ {
+   GST_DEBUG ("%s", message);
+ }
+@@ -212,7 +228,11 @@ typedef struct
+ 
+ /* for counting the number of FluidSynth settings properties */
+ static void
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+ settings_foreach_count (void *data, char *name, int type)
++#else
++settings_foreach_count (void *data, const char *name, int type)
++#endif
+ {
+   int *count = (int *) data;
+   *count = *count + 1;
+@@ -220,7 +240,11 @@ settings_foreach_count (void *data, char
+ 
+ /* add each FluidSynth setting as a GObject property */
+ static void
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+ settings_foreach_func (void *data, char *name, int type)
++#else
++settings_foreach_func (void *data, const char *name, int type)
++#endif
+ {
+   ForeachBag *bag = (ForeachBag *) data;
+   GParamSpec *spec;
+@@ -231,18 +255,30 @@ settings_foreach_func (void *data, char 
+   switch (type) {
+     case FLUID_NUM_TYPE:
+       fluid_settings_getnum_range (bag->settings, name, &dmin, &dmax);
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+       ddef = fluid_settings_getnum_default (bag->settings, name);
++#else
++      if (fluid_settings_getnum_default (bag->settings, name, &ddef) != FLUID_OK) ddef = 0;
++#endif
+       spec = g_param_spec_double (name, name, name, dmin, dmax, ddef,
+           G_PARAM_READWRITE);
+       break;
+     case FLUID_INT_TYPE:
+       fluid_settings_getint_range (bag->settings, name, &imin, &imax);
++#if FLUIDSYNTH_VERSION_MAJOR < 2
+       idef = fluid_settings_getint_default (bag->settings, name);
++#else
++      if (fluid_settings_getint_default (bag->settings, name, &idef) != FLUID_OK) idef = 0;
++#endif
+       spec = g_param_spec_int (name, name, name, imin, imax, idef,
+           G_PARAM_READWRITE);
+       break;
+     case FLUID_STR_TYPE:
+-      defstr = fluid_settings_getstr_default (bag->settings, name);
++#if FLUIDSYNTH_VERSION_MAJOR < 2
++      fluid_settings_getstr_default (bag->settings, name);
++#else
++      if (fluid_settings_getstr_default (bag->settings, name,&defstr) != FLUID_OK) defstr = 0;
++#endif
+       spec = g_param_spec_string (name, name, name, defstr, G_PARAM_READWRITE);
+       break;
+     case FLUID_SET_TYPE:
+@@ -582,9 +618,9 @@ gstbt_fluid_synth_get_property (GObject 
+           g_value_set_double (value, d);
+         break;
+       case G_TYPE_STRING:
+-        retval = fluid_settings_getstr (src->settings, name, &s);
++        retval = fluid_settings_dupstr (src->settings, name, &s);
+         if (retval)
+-          g_value_set_string (value, s);
++          g_value_take_string (value, s);
+         break;
+       default:
+         g_critical ("Unexpected FluidSynth dynamic property type");
+@@ -666,11 +702,14 @@ gstbt_fluid_synth_dispose (GObject * obj
+     delete_fluid_midi_driver (gstsynth->midi);
+   if (gstsynth->midi_router)
+     delete_fluid_midi_router (gstsynth->midi_router);
++  if (gstsynth->cmd_handler)
++    delete_fluid_cmd_handler (gstsynth->cmd_handler);
+   if (gstsynth->fluid)
+     delete_fluid_synth (gstsynth->fluid);
+ 
+   gstsynth->midi = NULL;
+   gstsynth->midi_router = NULL;
++  gstsynth->cmd_handler = NULL;
+   gstsynth->fluid = NULL;
+ 
+   g_free (gstsynth->instrument_patch_path);
+@@ -714,14 +753,21 @@ gstbt_fluid_synth_init (GstBtFluidSynth 
+   /* create MIDI router to send MIDI to FluidSynth */
+   src->midi_router =
+       new_fluid_midi_router (src->settings,
+-      fluid_synth_handle_midi_event, (void *) src);
++      fluid_synth_handle_midi_event, src->fluid);
+   if (src->midi_router) {
+-    fluid_synth_set_midi_router (src->fluid, src->midi_router);
+-    src->midi =
+-        new_fluid_midi_driver (src->settings,
+-        fluid_midi_router_handle_midi_event, (void *) (src->midi_router));
+-    if (!src->midi)
+-      g_warning ("Failed to create FluidSynth MIDI input driver");
++#if FLUIDSYNTH_VERSION_MAJOR < 2
++    src->cmd_handler = new_fluid_cmd_handler (src->fluid);
++#else
++    src->cmd_handler = new_fluid_cmd_handler (src->fluid,NULL);
++#endif
++    if (src->cmd_handler) {
++      src->midi = new_fluid_midi_driver (src->settings,
++          fluid_midi_router_handle_midi_event, (void *) (src->midi_router));
++      if (!src->midi)
++        g_warning ("Failed to create FluidSynth MIDI input driver");
++    } else {
++      g_warning ("Failed to create FluidSynth MIDI cmd handler");
++    }
+   } else
+     g_warning ("Failed to create MIDI input router");
+ 
+@@ -874,7 +920,7 @@ gstbt_fluid_synth_class_init (GstBtFluid
+       g_param_spec_enum ("chorus-waveform", "Chorus waveform",
+           "Chorus waveform type",
+           CHORUS_WAVEFORM_TYPE,
+-          FLUID_CHORUS_DEFAULT_TYPE,
++          FLUID_CHORUS_MOD_SINE,
+           G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
+ 



Home | Main Index | Thread Index | Old Index