summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2016-05-23 21:17:43 +0100
committerCarl Hetherington <cth@carlh.net>2016-05-23 21:17:43 +0100
commitab3db3166a2217eb9616fea068a952330a9e64a2 (patch)
tree030c8cae6470679229818675d947a40216fa775f
parent4f82cf8273f92719465ff3faec50c8e3a84561b3 (diff)
parent3739c62f626b65da929d37fb7efc44a8e349e6f1 (diff)
Merge branch 'master' of ssh://git.carlh.net/home/carl/git/dcpomatic
-rw-r--r--ChangeLog4
-rw-r--r--cscript2
-rw-r--r--src/lib/image_examiner.cc2
-rw-r--r--src/lib/magick_image_proxy.cc5
-rw-r--r--src/lib/raw_convert.cc36
-rw-r--r--src/lib/raw_convert.h8
-rw-r--r--src/lib/signal_manager.h2
-rw-r--r--src/lib/wscript5
-rw-r--r--test/util_test.cc9
-rw-r--r--wscript26
10 files changed, 90 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index 3398aa1bd..8092617c5 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2016-05-23 c.hetherington <cth@carlh.net>
+
+ * Fix missing words in properties window (#874).
+
2016-05-23 Carl Hetherington <cth@carlh.net>
* Version 2.8.4 released.
diff --git a/cscript b/cscript
index 1408d2d3f..dee81640b 100644
--- a/cscript
+++ b/cscript
@@ -229,7 +229,7 @@ def dependencies(target):
ffmpeg_options = {}
return (('ffmpeg-cdist', 'cd922b8', ffmpeg_options),
- ('libdcp', '92bec59'),
+ ('libdcp', '4e6b78d'),
('libsub', 'v1.1.12'))
def configure_options(target):
diff --git a/src/lib/image_examiner.cc b/src/lib/image_examiner.cc
index e0be15794..b9cd1caf5 100644
--- a/src/lib/image_examiner.cc
+++ b/src/lib/image_examiner.cc
@@ -43,7 +43,7 @@ ImageExaminer::ImageExaminer (shared_ptr<const Film> film, shared_ptr<const Imag
: _film (film)
, _image_content (content)
{
-#ifdef DCPOMATIC_IMAGE_MAGICK
+#ifdef DCPOMATIC_HAVE_MAGICKCORE_NAMESPACE
using namespace MagickCore;
#endif
boost::filesystem::path path = content->path(0).string ();
diff --git a/src/lib/magick_image_proxy.cc b/src/lib/magick_image_proxy.cc
index cb168ce63..98054b8df 100644
--- a/src/lib/magick_image_proxy.cc
+++ b/src/lib/magick_image_proxy.cc
@@ -108,9 +108,10 @@ MagickImageProxy::image (optional<dcp::NoteHandler>) const
/* Write line-by-line here as _image must be aligned, and write() cannot be told about strides */
uint8_t* p = _image->data()[0];
for (int i = 0; i < size.height; ++i) {
-#ifdef DCPOMATIC_IMAGE_MAGICK
+#ifdef DCPOMATIC_HAVE_MAGICKCORE_NAMESPACE
using namespace MagickCore;
-#else
+#endif
+#ifdef DCPOMATIC_HAVE_MAGICKLIB_NAMESPACE
using namespace MagickLib;
#endif
magick_image->write (0, i, size.width, 1, "RGB", CharPixel, p);
diff --git a/src/lib/raw_convert.cc b/src/lib/raw_convert.cc
new file mode 100644
index 000000000..4325f526f
--- /dev/null
+++ b/src/lib/raw_convert.cc
@@ -0,0 +1,36 @@
+/*
+ Copyright (C) 2014-2016 Carl Hetherington <cth@carlh.net>
+
+ 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 2 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., 675 Mass Ave, Cambridge, MA 02139, USA.
+
+*/
+
+#include "raw_convert.h"
+
+using std::string;
+
+template <>
+string
+raw_convert<string, string> (string v, int)
+{
+ return v;
+}
+
+template <>
+string
+raw_convert<string, char const *> (char const * v, int)
+{
+ return v;
+}
diff --git a/src/lib/raw_convert.h b/src/lib/raw_convert.h
index 6e55d49cf..985c4e643 100644
--- a/src/lib/raw_convert.h
+++ b/src/lib/raw_convert.h
@@ -44,4 +44,12 @@ raw_convert (Q v, int precision = 16)
return r;
}
+template <>
+std::string
+raw_convert<std::string, char const *> (char const * v, int);
+
+template <>
+std::string
+raw_convert<std::string, std::string> (std::string v, int);
+
#endif
diff --git a/src/lib/signal_manager.h b/src/lib/signal_manager.h
index 62afacade..8bee68c3c 100644
--- a/src/lib/signal_manager.h
+++ b/src/lib/signal_manager.h
@@ -38,6 +38,8 @@ public:
_ui_thread = boost::this_thread::get_id ();
}
+ virtual ~SignalManager () {}
+
/* Do something next time the UI is idle */
template <typename T>
void when_idle (T f) {
diff --git a/src/lib/wscript b/src/lib/wscript
index fe4eac114..6a9f5106c 100644
--- a/src/lib/wscript
+++ b/src/lib/wscript
@@ -115,11 +115,12 @@ sources = """
send_problem_report_job.cc
server.cc
string_log_entry.cc
+ raw_convert.cc
+ subtitle_content.cc
+ subtitle_decoder.cc
text_subtitle.cc
text_subtitle_content.cc
text_subtitle_decoder.cc
- subtitle_content.cc
- subtitle_decoder.cc
timer.cc
transcode_job.cc
transcoder.cc
diff --git a/test/util_test.cc b/test/util_test.cc
index e296229e1..9dcd05339 100644
--- a/test/util_test.cc
+++ b/test/util_test.cc
@@ -1,5 +1,5 @@
/*
- Copyright (C) 2012-2014 Carl Hetherington <cth@carlh.net>
+ Copyright (C) 2012-2016 Carl Hetherington <cth@carlh.net>
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
@@ -23,6 +23,7 @@
#include <boost/test/unit_test.hpp>
#include "lib/util.h"
+#include "lib/raw_convert.h"
#include "lib/exceptions.h"
using std::string;
@@ -85,3 +86,9 @@ BOOST_AUTO_TEST_CASE (seconds_to_approximate_hms_test)
BOOST_CHECK_EQUAL (seconds_to_approximate_hms (3600 + 40 * 60), "1h 40m");
BOOST_CHECK_EQUAL (seconds_to_approximate_hms (13 * 3600 + 40 * 60), "14h");
}
+
+BOOST_AUTO_TEST_CASE (raw_convert_test)
+{
+ BOOST_CHECK_EQUAL (raw_convert<string> ("foo"), "foo");
+ BOOST_CHECK_EQUAL (raw_convert<string> ("foo bar"), "foo bar");
+}
diff --git a/wscript b/wscript
index 78454565f..dd2e18e0e 100644
--- a/wscript
+++ b/wscript
@@ -78,11 +78,14 @@ def configure(conf):
'-Wall',
'-Wno-attributes',
'-Wextra',
- '-Wno-unused-result',
# Remove auto_ptr warnings from libxml++-2.6
'-Wno-deprecated-declarations',
'-D_FILE_OFFSET_BITS=64'])
+ gcc = conf.env['CC_VERSION']
+ if int(gcc[0]) >= 4 and int(gcc[1]) > 1:
+ conf.env.append_value('CXXFLAGS', ['-Wno-unused-result'])
+
if conf.options.enable_debug:
conf.env.append_value('CXXFLAGS', ['-g', '-DDCPOMATIC_DEBUG', '-fno-omit-frame-pointer'])
else:
@@ -157,7 +160,7 @@ def configure(conf):
conf.env.STLIB_CURL = ['curl']
conf.env.LIB_CURL = ['ssh2', 'idn']
else:
- conf.check_cfg(package='libcurl', args='--cflags --libs', uselib_store='CURL', mandatory=True)
+ conf.check_cfg(package='libcurl', args='--cflags --libs', atleast_version='7.19.1', uselib_store='CURL', mandatory=True)
# libicu
if conf.check_cfg(package='icu-i18n', args='--cflags --libs', uselib_store='ICU', mandatory=False) is None:
@@ -196,6 +199,25 @@ def configure(conf):
if graphics is not None:
conf.env.append_value('CXXFLAGS', '-DDCPOMATIC_GRAPHICS_MAGICK')
+ # See if we are using the MagickCore or MagickLib namespaces
+ conf.check_cxx(fragment="""
+ #include <Magick++.h>
+ using namespace MagickCore;
+ """,
+ mandatory=False,
+ msg='Checking for MagickCore namespace',
+ okmsg='yes',
+ define_name='DCPOMATIC_HAVE_MAGICKCORE_NAMESPACE')
+
+ conf.check_cxx(fragment="""
+ #include <Magick++.h>
+ using namespace MagickLib
+ """,
+ mandatory=False,
+ msg='Checking for MagickLib namespace',
+ okmsg='yes',
+ define_name='DCPOMATIC_HAVE_MAGICKLIB_NAMESPACE')
+
# libzip
conf.check_cfg(package='libzip', args='--cflags --libs', uselib_store='ZIP', mandatory=True)