diff options
author | riggs <riggs@FreeBSD.org> | 2017-04-22 22:44:11 +0800 |
---|---|---|
committer | riggs <riggs@FreeBSD.org> | 2017-04-22 22:44:11 +0800 |
commit | e2d8b19ab6146a221345bb497ea5a9be2b7acdda (patch) | |
tree | ba786d49e786b7c45c8e692806bdf144a60bc95d /multimedia | |
parent | 584d519791d99c697a5ea9dd35b0cfeb0a935535 (diff) | |
download | freebsd-ports-gnome-e2d8b19ab6146a221345bb497ea5a9be2b7acdda.tar.gz freebsd-ports-gnome-e2d8b19ab6146a221345bb497ea5a9be2b7acdda.tar.zst freebsd-ports-gnome-e2d8b19ab6146a221345bb497ea5a9be2b7acdda.zip |
Fix build after dependencies enforce C++11
MFH: 2017Q2 (build fix blanket)
Diffstat (limited to 'multimedia')
8 files changed, 92 insertions, 1 deletions
diff --git a/multimedia/subtitleeditor/Makefile b/multimedia/subtitleeditor/Makefile index a0d03cd6aadf..80dca1a57f2e 100644 --- a/multimedia/subtitleeditor/Makefile +++ b/multimedia/subtitleeditor/Makefile @@ -17,7 +17,7 @@ LIB_DEPENDS= libglademm-2.4.so:devel/libglademm24 \ libenchant.so:textproc/enchant RUN_DEPENDS:= ${BUILD_DEPENDS} -USES= desktop-file-utils gettext gmake libtool pkgconfig +USES= compiler:c++11-lang desktop-file-utils gettext gmake libtool pkgconfig USE_GNOME= gtkmm24 intltool USE_GSTREAMER= good mm GNU_CONFIGURE= yes @@ -25,6 +25,7 @@ INSTALL_TARGET= install-strip INSTALLS_ICONS= yes CPPFLAGS+= -I${LOCALBASE}/include +CXXFLAGS+= -std=c++11 LDFLAGS+= -L${LOCALBASE}/lib OPTIONS_DEFINE= NLS OPENGL diff --git a/multimedia/subtitleeditor/files/patch-plugins_actions_documentmanagement_documentmanagement.cc b/multimedia/subtitleeditor/files/patch-plugins_actions_documentmanagement_documentmanagement.cc new file mode 100644 index 000000000000..9051db129027 --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-plugins_actions_documentmanagement_documentmanagement.cc @@ -0,0 +1,15 @@ +--- plugins/actions/documentmanagement/documentmanagement.cc.orig 2014-02-12 22:02:56 UTC ++++ plugins/actions/documentmanagement/documentmanagement.cc +@@ -177,9 +177,9 @@ public: + + ui_id = ui->new_merge_id(); + +- #define ADD_UI(name) ui->add_ui(ui_id, "/menubar/menu-file/"name, name, name); +- #define ADD_OPEN_UI(name) ui->add_ui(ui_id, "/menubar/menu-file/menu-open/"name, name, name); +- #define ADD_SAVE_UI(name) ui->add_ui(ui_id, "/menubar/menu-file/menu-save/"name, name, name); ++ #define ADD_UI(name) ui->add_ui(ui_id, "/menubar/menu-file/" name, name, name); ++ #define ADD_OPEN_UI(name) ui->add_ui(ui_id, "/menubar/menu-file/menu-open/" name, name, name); ++ #define ADD_SAVE_UI(name) ui->add_ui(ui_id, "/menubar/menu-file/menu-save/" name, name, name); + + ADD_UI("new-document"); + ADD_OPEN_UI("open-document"); diff --git a/multimedia/subtitleeditor/files/patch-plugins_actions_insertsubtitlefromkeyframe_insertsubtitlefromkeyframe.cc b/multimedia/subtitleeditor/files/patch-plugins_actions_insertsubtitlefromkeyframe_insertsubtitlefromkeyframe.cc new file mode 100644 index 000000000000..0c77346a1df9 --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-plugins_actions_insertsubtitlefromkeyframe_insertsubtitlefromkeyframe.cc @@ -0,0 +1,11 @@ +--- plugins/actions/insertsubtitlefromkeyframe/insertsubtitlefromkeyframe.cc.orig 2014-02-12 22:02:55 UTC ++++ plugins/actions/insertsubtitlefromkeyframe/insertsubtitlefromkeyframe.cc +@@ -103,7 +103,7 @@ public: + se_debug(SE_DEBUG_PLUGINS); + + bool has_doc = (get_current_document() != NULL); +- bool has_kf = (player()->get_keyframes()); ++ bool has_kf = static_cast<bool>(player()->get_keyframes()); + bool has_media = player()->get_state() != Player::NONE; + + action_group->get_action("insert-subtitle-between-keyframes")->set_sensitive(has_doc && has_kf && has_media); diff --git a/multimedia/subtitleeditor/files/patch-plugins_actions_keyframesmanagement_keyframesmanagement.cc b/multimedia/subtitleeditor/files/patch-plugins_actions_keyframesmanagement_keyframesmanagement.cc new file mode 100644 index 000000000000..ecfcb89d47e6 --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-plugins_actions_keyframesmanagement_keyframesmanagement.cc @@ -0,0 +1,11 @@ +--- plugins/actions/keyframesmanagement/keyframesmanagement.cc.orig 2014-02-12 22:02:57 UTC ++++ plugins/actions/keyframesmanagement/keyframesmanagement.cc +@@ -223,7 +223,7 @@ public: + se_debug(SE_DEBUG_PLUGINS); + + bool has_doc = (get_current_document() != NULL); +- bool has_kf = (player()->get_keyframes()); ++ bool has_kf = static_cast<bool>(player()->get_keyframes()); + bool has_media = player()->get_state() != Player::NONE; + + #define SET_SENSITIVE(action, state) { Glib::RefPtr<Gtk::Action> act = action_group->get_action(action); if(act) act->set_sensitive(state); else g_warning(action); } diff --git a/multimedia/subtitleeditor/files/patch-plugins_subtitleformats_sami_sami.cc b/multimedia/subtitleeditor/files/patch-plugins_subtitleformats_sami_sami.cc new file mode 100644 index 000000000000..e6f405590140 --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-plugins_subtitleformats_sami_sami.cc @@ -0,0 +1,11 @@ +--- plugins/subtitleformats/sami/sami.cc.orig 2014-02-12 22:02:58 UTC ++++ plugins/subtitleformats/sami/sami.cc +@@ -263,7 +263,7 @@ public: + { + inptr = (char *)(line.c_str()); + p = tmptext; +- p = '\0'; ++ *p = '\0'; + + state = SAMI_STATE_INIT; + continue; diff --git a/multimedia/subtitleeditor/files/patch-src_subtitleview.cc b/multimedia/subtitleeditor/files/patch-src_subtitleview.cc new file mode 100644 index 000000000000..dee3f36b5dc0 --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-src_subtitleview.cc @@ -0,0 +1,11 @@ +--- src/subtitleview.cc.orig 2014-02-12 22:02:59 UTC ++++ src/subtitleview.cc +@@ -1370,7 +1370,7 @@ bool SubtitleView::on_key_press_event(Gd + { + int num; + std::istringstream ss(event->string); +- bool is_num = ss >> num != 0; ++ bool is_num = static_cast<bool>(ss >> num); + // Update only if it's different + if(is_num != get_enable_search()) + set_enable_search(is_num); diff --git a/multimedia/subtitleeditor/files/patch-src_utility.h b/multimedia/subtitleeditor/files/patch-src_utility.h new file mode 100644 index 000000000000..51c92fab209c --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-src_utility.h @@ -0,0 +1,20 @@ +--- src/utility.h.orig 2014-02-12 22:03:00 UTC ++++ src/utility.h +@@ -72,7 +72,7 @@ bool from_string(const std::string &src, + std::istringstream s(src); + // return s >> dest != 0; + +- bool state = s >> dest != 0; ++ bool state = static_cast<bool>(s >> dest); + + if(!state) + se_debug_message(SE_DEBUG_UTILITY, "string:'%s'failed.", src.c_str()); +@@ -92,7 +92,7 @@ bool from_string(const Glib::ustring &sr + std::istringstream s(src); + // return s >> dest != 0; + +- bool state = s >> dest != 0; ++ bool state = static_cast<bool>(s >> dest); + + if(!state) + se_debug_message(SE_DEBUG_UTILITY, "string:'%s'failed.", src.c_str()); diff --git a/multimedia/subtitleeditor/files/patch-src_vp_gstplayer.cc b/multimedia/subtitleeditor/files/patch-src_vp_gstplayer.cc new file mode 100644 index 000000000000..6950c256cd33 --- /dev/null +++ b/multimedia/subtitleeditor/files/patch-src_vp_gstplayer.cc @@ -0,0 +1,11 @@ +--- src/vp/gstplayer.cc.orig 2014-02-12 22:02:59 UTC ++++ src/vp/gstplayer.cc +@@ -261,7 +261,7 @@ bool GstPlayer::seek(long start, long en + gint64 gend = end * Gst::MILLI_SECOND; + + se_debug_message(SE_DEBUG_VIDEO_PLAYER, +- "pipeline->seek(%" GST_TIME_FORMAT", %"GST_TIME_FORMAT")", ++ "pipeline->seek(%" GST_TIME_FORMAT", %" GST_TIME_FORMAT")", + GST_TIME_ARGS(gstart), GST_TIME_ARGS(gend)); + + bool ret = m_pipeline->seek( |