Created attachment 150133 [details] patch to fix ffmpegthumbnailer build on FreeBSD 8.4 The multimedia/ffmpegthumbnailer port version 2.0.9 build fails on FreeBSD 8.4. I suspect that FreeBSD 9.x is also affected since the base compiler is still gcc 4.2.1. ===> Building for ffmpegthumbnailer-2.0.9 /usr/bin/make all-recursive Making all in man depbase=`echo main.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`; c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -O2 -pipe -fno-strict-aliasing -std=c++11 -MT main.o -MD -MP -MF $depbase.Tpo -c -o main.o main.cpp && mv -f $depbase.Tpo $depbase.Po /bin/sh ./libtool --tag=CXX --mode=compile c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -fno-strict-aliasing -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-moviedecoder.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-moviedecoder.Tpo -c -o libffmpegthumbnailer/libffmpegthumbnailer_la-moviedecoder.lo `test -f 'libffmpegthumbnailer/moviedecoder.cpp' || echo './'`libffmpegthumbnailer/moviedecoder.cpp /bin/sh ./libtool --tag=CXX --mode=compile c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -fno-strict-aliasing -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-stringoperations.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-stringoperations.Tpo -c -o libffmpegthumbnailer/libffmpegthumbnailer_la-stringoperations.lo `test -f 'libffmpegthumbnailer/stringoperations.cpp' || echo './'`libffmpegthumbnailer/stringoperations.cpp /bin/sh ./libtool --tag=CXX --mode=compile c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -fno-strict-aliasing -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-videothumbnailer.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-videothumbnailer.Tpo -c -o libffmpegthumbnailer/libffmpegthumbnailer_la-videothumbnailer.lo `test -f 'libffmpegthumbnailer/videothumbnailer.cpp' || echo './'`libffmpegthumbnailer/videothumbnailer.cpp cc1plus: error: unrecognized command line option "-std=c++11" libtool: compile: c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -fno-strict-aliasing -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-moviedecoder.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-moviedecoder.Tpo -c libffmpegthumbnailer/moviedecoder.cpp -fPIC -DPIC -o libffmpegthumbnailer/.libs/libffmpegthumbnailer_la-moviedecoder.o cc1plus: error: unrecognized command line option "-std=c++11" *** Error code 1 *** Error code 1 libtool: compile: c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -fno-strict-aliasing -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-videothumbnailer.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-videothumbnailer.Tpo -c libffmpegthumbnailer/videothumbnailer.cpp -fPIC -DPIC -o libffmpegthumbnailer/.libs/libffmpegthumbnailer_la-videothumbnailer.o libtool: compile: c++ -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -fno-strict-aliasing -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-stringoperations.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-stringoperations.Tpo -c libffmpegthumbnailer/stringoperations.cpp -fPIC -DPIC -o libffmpegthumbnailer/.libs/libffmpegthumbnailer_la-stringoperations.o cc1plus: error: unrecognized command line option "-std=c++11" cc1plus: error: unrecognized command line option "-std=c++11" *** Error code 1 *** Error code 1 4 errors *** Error code 1 1 error *** Error code 2 1 error ===> Compilation failed unexpectedly. My first attempt at fixing was to add "USES= compiler:c++11-lib" to the Makefile. That got the build to go a bit further: libtool: compile: g++48 -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -Wl,-rpath=/usr/local/lib/gcc48 -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc48 -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-filmstripfilter.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-filmstripfilter.Tpo -c libffmpegthumbnailer/filmstripfilter.cpp -o libffmpegthumbnailer/libffmpegthumbnailer_la-filmstripfilter.o >/dev/null 2>&1 mv -f libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-filmstripfilter.Tpo libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-filmstripfilter.Plo In file included from libffmpegthumbnailer/jpegwriter.h:24:0, from libffmpegthumbnailer/jpegwriter.cpp:17: /usr/local/include/jpeglib.h:954:30: error: 'FILE' has not been declared EXTERN(void) jpeg_stdio_dest JPP((j_compress_ptr cinfo, FILE * outfile)); ^ /usr/local/include/jpeglib.h:955:29: error: 'FILE' has not been declared EXTERN(void) jpeg_stdio_src JPP((j_decompress_ptr cinfo, FILE * infile)); ^ In file included from libffmpegthumbnailer/jpegwriter.cpp:17:0: libffmpegthumbnailer/jpegwriter.h:48:5: error: 'FILE' does not name a type FILE* m_pFile; ^ libtool: compile: g++48 -DHAVE_CONFIG_H -I. -I/usr/local/include -D__STDC_CONSTANT_MACROS -I/usr/local/include -I/usr/local/include/libpng15 -O2 -pipe -Wl,-rpath=/usr/local/lib/gcc48 -fno-strict-aliasing -Wl,-rpath=/usr/local/lib/gcc48 -std=c++11 -MT libffmpegthumbnailer/libffmpegthumbnailer_la-pngwriter.lo -MD -MP -MF libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-pngwriter.Tpo -c libffmpegthumbnailer/pngwriter.cpp -o libffmpegthumbnailer/libffmpegthumbnailer_la-pngwriter.o >/dev/null 2>&1 libffmpegthumbnailer/jpegwriter.cpp: In constructor 'ffmpegthumbnailer::JpegWriter::JpegWriter(const string&)': libffmpegthumbnailer/jpegwriter.cpp:44:3: error: class 'ffmpegthumbnailer::JpegWriter' does not have any field named 'm_pFile' , m_pFile(NULL) ^ libffmpegthumbnailer/jpegwriter.cpp:48:2: error: 'm_pFile' was not declared in this scope m_pFile = outputFile == "-" ? stdout : fopen(outputFile.c_str(), "wb"); ^ libffmpegthumbnailer/jpegwriter.cpp: In constructor 'ffmpegthumbnailer::JpegWriter::JpegWriter(std::vector<unsigned char>&)': libffmpegthumbnailer/jpegwriter.cpp:60:3: error: class 'ffmpegthumbnailer::JpegWriter' does not have any field named 'm_pFile' , m_pFile(NULL) ^ libffmpegthumbnailer/jpegwriter.cpp: In destructor 'virtual ffmpegthumbnailer::JpegWriter::~JpegWriter()': libffmpegthumbnailer/jpegwriter.cpp:76:9: error: 'm_pFile' was not declared in this scope if (m_pFile) ^ *** Error code 1 mv -f libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-pngwriter.Tpo libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-pngwriter.Plo mv -f libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-videothumbnailer.Tpo libffmpegthumbnailer/.deps/libffmpegthumbnailer_la-videothumbnailer.Plo 1 error *** Error code 1 1 error *** Error code 2 1 error ===> Compilation failed unexpectedly. I found a patch for the latter problem here: <http://sourceforge.net/p/cygwin-ports/ffmpegthumbnailer/ci/master/tree/2.0.6-jpeg.patch> With those two changes, I can now build ffmpegthumbnailer on FreeBSD 8.4. The build on FreeBSD 10.1 appears to be unaffected.
Maintainer CC'd
(In reply to Bugzilla Automation from comment #1) > Maintainer CC'd I've tested on 8x. Patch fixes the problem.
(In reply to Don Lewis from comment #0) > Created attachment 150133 [details] > patch to fix ffmpegthumbnailer build on FreeBSD 8.4 > > The multimedia/ffmpegthumbnailer port version 2.0.9 build fails on FreeBSD > 8.4. I suspect that FreeBSD 9.x is also affected since the base compiler is > still gcc 4.2.1. I can confirm both that this problem exists with 9.3/i386, and that with this patch I was able to compile. Thanks.
Created attachment 150385 [details] poudriere testport result on 9.2/amd64 In the evening of Dec 2nd, I had come up with the patch to make this build in poudriere for 9.2/amd64. But, left it to later to see about submitting. The only thing I did for mine was add 'compiler:c++11x-lang' to the 'USES=' line.
(In reply to Lawrence Chen from comment #4) > Created attachment 150385 [details] > poudriere testport result on 9.2/amd64 > > In the evening of Dec 2nd, I had come up with the patch to make this build > in poudriere for 9.2/amd64. But, left it to later to see about submitting. > > The only thing I did for mine was add 'compiler:c++11x-lang' to the 'USES=' > line. For 8x the header is still needs to be modified.
A commit references this bug: Author: riggs Date: Thu Dec 25 22:44:00 UTC 2014 New revision: 375609 URL: https://svnweb.freebsd.org/changeset/ports/375609 Log: Fix build on 8.x systems PR: 195600 Submitted by: truckman@FreeBSD.org Approved by: clutton@zoho.com (maintainer) Changes: head/multimedia/ffmpegthumbnailer/Makefile head/multimedia/ffmpegthumbnailer/files/patch-libffmpegthumbnailer_jpegwriter.h
Committed, thanks!