<blockquote style='border-left:2px solid #CCCCCC;padding:0 1em' class="quote dark-border-color"><div class="quote light-border-color">
<div class="quote-author" style="font-weight: bold;">Michael Stahl-2 wrote</div>
<div class="quote-message">
it is definitely a bug somewhere if HAVE_POPPLER_VERSION_H isn't set for
a current version of poppler.

e.g. on Fedora 22 i have /usr/include/poppler/cpp/poppler-version.h and
HAVE_POPPLER_VERSION_H set.

maybe look at config.log where it checks for poppler-version.h what the
error is.
</div>
</div></blockquote>

<p>Turns out poppler-version.h was missing; in Ubuntu it comes in the libpoppler-cpp-dev package. </p>

<p>Here's what happens without it.</p>
<p>Output from autogen.sh:</p>
<pre>
checking for POPPLER... yes
checking cpp/poppler-version.h usability... no
checking cpp/poppler-version.h presence... no
checking for cpp/poppler-version.h... no
</pre>

<p>config.log:</p>
<pre>
configure:36446: checking for POPPLER
configure:36453: $PKG_CONFIG --exists --print-errors "poppler >= 0.12.0 "
configure:36456: $? = 0
configure:36470: $PKG_CONFIG --exists --print-errors "poppler >= 0.12.0 "
configure:36473: $? = 0
configure:36531: result: yes
configure:36545: checking cpp/poppler-version.h usability
configure:36545: g++ -c -O3 -march=native -pipe -I/usr/include/poppler    -I/usr/include/poppler  conftest.cpp >&5
conftest.cpp:138:33: fatal error: cpp/poppler-version.h: No such file or directory
compilation terminated.
configure:36545: $? = 1
configure: failed program was:
| /* confdefs.h */
| #include <cpp/poppler-version.h>
configure:36545: result: no
configure:36545: checking cpp/poppler-version.h presence
configure:36545: g++ -E   -I/usr/include/poppler  conftest.cpp
conftest.cpp:105:33: fatal error: cpp/poppler-version.h: No such file or directory
compilation terminated.
configure:36545: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "LibreOffice"
| #define PACKAGE_TARNAME "libreoffice"
| #define PACKAGE_VERSION "5.1.0.0.alpha1+"
...
| #include <cpp/poppler-version.h>
configure:36545: result: no
configure:36545: checking cpp/poppler-version.h presence
configure:36545: g++ -E   -I/usr/include/poppler  conftest.cpp
conftest.cpp:105:33: fatal error: cpp/poppler-version.h: No such file or directory
compilation terminated.
configure:36545: $? = 1
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "LibreOffice"
| #define PACKAGE_TARNAME "libreoffice"
| #define PACKAGE_VERSION "5.1.0.0.alpha1+"
...
| /* end confdefs.h.  */
| #include <cpp/poppler-version.h>
configure:36545: result: no
configure:36545: checking for cpp/poppler-version.h
configure:36545: result: no
configure:36630: checking whether to build the Wiki Publisher extension
</pre>
<p><a href="http://pastebin.com/CGrUQwuh" target="_top" rel="nofollow" link="external">http://pastebin.com/CGrUQwuh</a></p>

<p>So configure does check for the file but ignores the failed test. </p>

<p>There's also GfxState.h, that comes in yet another package libpoppler-private-dev and is also needed, but configure doesn't test for it. Maybe they used to be in the same package so only one test was needed?</p>

        
        
        
<br/><hr align="left" width="300" />
View this message in context: <a href="http://nabble.documentfoundation.org/System-POPPLER-VERSION-redefined-won-t-build-tp4165697p4165894.html">Re: System POPPLER_VERSION redefined, won't build</a><br/>
Sent from the <a href="http://nabble.documentfoundation.org/Dev-f1639786.html">Dev mailing list archive</a> at Nabble.com.<br/>