Subject: Re: qt4 doesn't build on NetBSD 3.x
To: None <pkgsrc-users@NetBSD.org>
From: Geert Hendrickx <ghen@telenet.be>
List: pkgsrc-users
Date: 12/19/2007 06:13:45
On Wed, Dec 19, 2007 at 05:21:29AM -0800, Geert Hendrickx wrote:
> This doesn't build on NetBSD 3.x because it doesn't have strtold(3)...
>
> /scratch/work/x11/qt4-libs/work/qt-x11-opensource-src-4.3.3/src/script/qscriptlexer.cpp: In member function `int QScript::Lexer::lex()':
> /scratch/work/x11/qt4-libs/work/qt-x11-opensource-src-4.3.3/src/script/qscriptlexer.cpp:711: error: ` strtold' undeclared (first use this function)
> /scratch/work/x11/qt4-libs/work/qt-x11-opensource-src-4.3.3/src/script/qscriptlexer.cpp:711: error: (Each undeclared identifier is reported only once for each function it appears in.)
> make: *** [qscriptlexer.o] Error 1
> *** Error code 2
This can be fixed with an updated patches/patch-an:
--- src/script/qscriptlexer.cpp.orig 2007-12-04 17:43:06.000000000 +0100
+++ src/script/qscriptlexer.cpp
@@ -704,7 +704,7 @@ int QScript::Lexer::lex()
double dval = 0;
if (state == Number) {
-#if defined(Q_WS_WIN) || defined(Q_OS_SOLARIS) || defined(Q_OS_IRIX) || defined(Q_CC_HPACC) || defined(Q_OS_AIX) || defined(Q_OS_OPENBSD)
+#if defined(Q_WS_WIN) || defined(Q_OS_SOLARIS) || defined(Q_OS_IRIX) || defined(Q_CC_HPACC) || defined(Q_OS_AIX) || defined(Q_OS_OPENBSD) || defined(__DragonFly__) || ( defined(Q_OS_NETBSD) && (__NetBSD_Version__ < 400000000) )
// ### This may cause autotest failure, but that's just plain weird...
dval = strtod(buffer8, 0L);
#else
but then I hit the next error:
painting/qdrawhelper.cpp: In function `uint detectCPUFeatures()':
painting/qdrawhelper.cpp:5295: error: can't find a register in class `Q_REGS' while reloading `asm'
gmake[1]: *** [.obj/release-shared/qdrawhelper.lo] Error 1
gmake[1]: Leaving directory `/scratch/work/x11/qt4-libs/work/qt-x11-opensource-src-4.3.3/src/gui'
gmake: *** [sub-gui-sub_src_target_ordered] Error 2
*** Error code 2
Geert