[beast] BSE: compile bsecompat as C++ source
- From: Tim Janik <timj src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [beast] BSE: compile bsecompat as C++ source
- Date: Mon, 4 Jul 2011 20:01:07 +0000 (UTC)
commit b8e37ec64df5086647c4fc88c35040391e4b6cc0
Author: Stefan Westerfeld <stefan space twc de>
Date: Fri Jul 1 17:12:30 2011 +0200
BSE: compile bsecompat as C++ source
bse/Makefile.am | 2 +-
bse/{bsecompat.c => bsecompat.cc} | 18 +++++++++---------
2 files changed, 10 insertions(+), 10 deletions(-)
---
diff --git a/bse/Makefile.am b/bse/Makefile.am
index 718c455..1e586a9 100644
--- a/bse/Makefile.am
+++ b/bse/Makefile.am
@@ -85,7 +85,7 @@ bse_sources = $(strip \
bsesubsynth.c bsesuper.c bsetrack.c bsetype.c \
bseutils.c bsemidivoice.c bsewave.c bsewaveosc.c \
bsecsynth.c bsewaverepo.c bseladspamodule.c bsepcmwriter.c \
- bsecompat.c bseundostack.c bsemidiinput.c bsemididecoder.c \
+ bsecompat.cc bseundostack.c bsemidiinput.c bsemididecoder.c \
bsenote.cc bsemidifile.c bseblockutils.cc \
bsecxxvalue.cc bsecxxutils.cc bsecxxbase.cc bsecxxclosure.cc \
bsecxxarg.cc bsecxxmodule.cc bsecxxplugin.cc bseloader.c \
diff --git a/bse/bsecompat.c b/bse/bsecompat.cc
similarity index 85%
rename from bse/bsecompat.c
rename to bse/bsecompat.cc
index 299480c..1ea1ba0 100644
--- a/bse/bsecompat.c
+++ b/bse/bsecompat.cc
@@ -27,7 +27,7 @@ bse_compat_rewrite_type_name (BseStorage *storage,
const guint vmajor = storage->major_version;
const guint vminor = storage->minor_version;
const guint vmicro = storage->micro_version;
- struct { guint vmajor, vminor, vmicro; gchar *old, *new; } type_changes[] = {
+ struct { guint vmajor, vminor, vmicro; const gchar *old_type, *new_type; } type_changes[] = {
{ 0, 5, 1, "BseSNet", "BseCSynth" },
{ 0, 5, 4, "BseMonoKeyboard", "BseMidiInput" },
{ 0, 5, 4, "BseMidiIController", "BseMidiController" },
@@ -45,8 +45,8 @@ bse_compat_rewrite_type_name (BseStorage *storage,
type_changes[i].vmajor,
type_changes[i].vminor,
type_changes[i].vmicro) <= 0 &&
- strcmp (type_name, type_changes[i].old) == 0)
- return g_strdup (type_changes[i].new);
+ strcmp (type_name, type_changes[i].old_type) == 0)
+ return g_strdup (type_changes[i].new_type);
return NULL;
}
@@ -58,7 +58,7 @@ bse_compat_rewrite_ichannel_ident (BseStorage *storage,
const guint vmajor = storage->major_version;
const guint vminor = storage->minor_version;
const guint vmicro = storage->micro_version;
- struct { guint vmajor, vminor, vmicro; gchar *type, *old, *new; } ichannel_changes[] = {
+ struct { guint vmajor, vminor, vmicro; const gchar *type, *old_channel, *new_channel; } ichannel_changes[] = {
{ 0, 6, 2, "ArtsStereoCompressor", "left-audio-in", "audio-in1" },
{ 0, 6, 2, "ArtsStereoCompressor", "right-audio-in", "audio-in2" },
{ 0, 6, 2, "ArtsCompressor", "audio-in", "audio-in1" },
@@ -70,8 +70,8 @@ bse_compat_rewrite_ichannel_ident (BseStorage *storage,
ichannel_changes[i].vminor,
ichannel_changes[i].vmicro) <= 0 &&
strcmp (type_name, ichannel_changes[i].type) == 0 &&
- strcmp (ichannel_ident, ichannel_changes[i].old) == 0)
- return g_strdup (ichannel_changes[i].new);
+ strcmp (ichannel_ident, ichannel_changes[i].old_channel) == 0)
+ return g_strdup (ichannel_changes[i].new_channel);
return NULL;
}
@@ -83,7 +83,7 @@ bse_compat_rewrite_ochannel_ident (BseStorage *storage,
const guint vmajor = storage->major_version;
const guint vminor = storage->minor_version;
const guint vmicro = storage->micro_version;
- struct { guint vmajor, vminor, vmicro; gchar *type, *old, *new; } ochannel_changes[] = {
+ struct { guint vmajor, vminor, vmicro; const gchar *type, *old_channel, *new_channel; } ochannel_changes[] = {
{ 0, 6, 2, "ArtsStereoCompressor", "left-audio-out", "audio-out1" },
{ 0, 6, 2, "ArtsStereoCompressor", "right-audio-out", "audio-out2" },
{ 0, 6, 2, "ArtsCompressor", "audio-out", "audio-out1" },
@@ -95,7 +95,7 @@ bse_compat_rewrite_ochannel_ident (BseStorage *storage,
ochannel_changes[i].vminor,
ochannel_changes[i].vmicro) <= 0 &&
strcmp (type_name, ochannel_changes[i].type) == 0 &&
- strcmp (ochannel_ident, ochannel_changes[i].old) == 0)
- return g_strdup (ochannel_changes[i].new);
+ strcmp (ochannel_ident, ochannel_changes[i].old_channel) == 0)
+ return g_strdup (ochannel_changes[i].new_channel);
return NULL;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]