Re: qt 5.8.0 on OpenBSD 6.0: compilation fails

2017-02-21 Thread Claus Assmann
On Tue, Feb 21, 2017, Stuart Henderson wrote:

> Some of the patches may be sane to upstream (or are backported and

Well, since the Qt source code comes with OpenBSD "support" [1] I
hoped it would at least compile without errors "out of the box".

[1] for example, qtbase/mkspecs/openbsd-g++/qmake.conf sets the
C++ compiler to eg++ and explicitly mentions OpenBSD 6.0.



Re: qt 5.8.0 on OpenBSD 6.0: compilation fails

2017-02-21 Thread Stuart Henderson
On 2017-02-21, Claus Assmann  wrote:
> On Tue, Feb 21, 2017, Rafael Sadowski wrote:
>
>> You will not be happy with these plan. Not without reason there is only
>> Qt 5.6 in -current. It is a hard piece of work for example see the patch
>> set onyl for qt core:
>
> Thanks, somehow the cvs checkout for ports/x11/qt5 on my system
> didn't include all those subdirectories (wrong cvs command?),
> so when I looked there I only found an empty ports/x11/qt5/patches/
> directory...
>
> Too bad Qt didn't (doesn't?) integrate those patches :-(
>
>

The port layout was changed significantly with the 5.6 update in
December (i.e. after 6.0).

Some of the patches may be sane to upstream (or are backported and
came from upstream already), others (strcpy->memcpy bits etc) not so
much. (And it looks like patch-src_network_kernel_qdnslookup_unix_cpp
is superceded by the upstream bit you can see just after the addition).



Re: qt 5.8.0 on OpenBSD 6.0: compilation fails

2017-02-21 Thread Claus Assmann
On Tue, Feb 21, 2017, Rafael Sadowski wrote:

> You will not be happy with these plan. Not without reason there is only
> Qt 5.6 in -current. It is a hard piece of work for example see the patch
> set onyl for qt core:

Thanks, somehow the cvs checkout for ports/x11/qt5 on my system
didn't include all those subdirectories (wrong cvs command?),
so when I looked there I only found an empty ports/x11/qt5/patches/
directory...

Too bad Qt didn't (doesn't?) integrate those patches :-(



Re: qt 5.8.0 on OpenBSD 6.0: compilation fails

2017-02-20 Thread Rafael Sadowski
On Mon Feb 20, 2017 at 02:48:58PM -0800, Claus Assmann wrote:
> (should this be asked on -ports?)
> 
> Maybe someone can give me a hint how to compile qt 5.8.0 on
> OpenBSD 6.0 (amd64)? (I would like to install it for some other
> SW which needs at least qt 5.7, but the pkg is 5.5).
> 

You will not be happy with these plan. Not without reason there is only
Qt 5.6 in -current. It is a hard piece of work for example see the patch
set onyl for qt core:

http://cvsweb.openbsd.org/cgi-bin/cvsweb/ports/x11/qt5/qtbase/patches/

If you really want to try it, start here: ports/x11/qt5 but do not
expect too much.

Rafael



qt 5.8.0 on OpenBSD 6.0: compilation fails

2017-02-20 Thread Claus Assmann
(should this be asked on -ports?)

Maybe someone can give me a hint how to compile qt 5.8.0 on
OpenBSD 6.0 (amd64)? (I would like to install it for some other
SW which needs at least qt 5.7, but the pkg is 5.5).

Currently I'm stuck at this:

eg++ -c -pipe -O2 -fPIC -std=c++1y -fvisibility=hidden
-fvisibility-inlines-hidden -fno-exceptions -Wall -W -Wvla -pthread
-DQT_NO_CAST_FROM_ASCII -DQT_BUILD_FONTDATABASE_SUPPORT_LIB -DQT_BUILDING_QT
-DQT_NO_CAST_TO_ASCII -DQT_ASCII_CAST_WARNINGS -DQT_MOC_COMPAT
-DQT_USE_QSTRINGBUILDER -DQT_DEPRECATED_WARNINGS
-DQT_DISABLE_DEPRECATED_BEFORE=0x05 -DQT_NO_EXCEPTIONS
-D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -DQT_NO_DEBUG -DQT_GUI_LIB
-DQT_CORE_LIB -I. -I../../../include -I../../../include/QtFontDatabaseSupport
-I../../../include/QtFontDatabaseSupport/5.8.0
-I../../../include/QtFontDatabaseSupport/5.8.0/QtFontDatabaseSupport
-I../../../include/QtGui/5.8.0 -I../../../include/QtGui/5.8.0/QtGui
-I../../../include/QtCore/5.8.0 -I../../../include/QtCore/5.8.0/QtCore
-I../../../include/QtGui -I../../../include/QtCore -I.moc -I/usr/X11R6/include
-I/usr/X11R6/include/libdrm -I/usr/X11R6/include/freetype2
-I/usr/X11R6/include -I/usr/X11R6/include/freetype2 -isystem /usr/include
-isystem /usr/local/include -I../../../mkspecs/openbsd-g++ -o
.obj/qbasicfontdatabase.o basic/qbasicfontdatabase.cpp
In file included from
/usr/local/lib/gcc/x86_64-unknown-openbsd6.0/4.9.3/include/x86intrin.h:29:0,
 from
/usr/local/include/c++/4.9.3/x86_64-unknown-openbsd6.0/bits/opt_random.h:33,
 from /usr/local/include/c++/4.9.3/random:50,
 from /usr/local/include/c++/4.9.3/bits/stl_algo.h:66,
 from /usr/local/include/c++/4.9.3/algorithm:62,
 from
../../../include/QtCore/../../src/corelib/global/qglobal.h:108,
 from ../../../include/QtCore/qglobal.h:1,
 from
../../../include/QtGui/../../src/gui/kernel/qtguiglobal.h:43,
 from ../../../include/QtGui/qtguiglobal.h:1,
 from
../../../include/QtGui/5.8.0/QtGui/qpa/../../../../../src/gui/text/qplatformf
ontdatabase.h:52,
 from
../../../include/QtGui/5.8.0/QtGui/qpa/qplatformfontdatabase.h:1,
 from basic/qbasicfontdatabase_p.h:54,
 from basic/qbasicfontdatabase.cpp:40:
/usr/include/mmintrin.h: In function '__m64 _mm_add_si64(__m64, __m64)':
/usr/include/mmintrin.h:312:72: error: cannot convert 'long long int' to
'__vector(1) long long int' for argument '1' to '__vector(1) long long int
__builtin_ia32_paddq(__vector(1) long long int, __vector(1) long long int)'
   return (__m64) __builtin_ia32_paddq ((long long)__m1, (long long)__m2);
^
[rest of the error message is below]

that particular code is inside:
#ifdef __SSE2__


According to dmesg the CPU supports this:
cpu0: Intel(R) Core(TM)2 CPU 6600 @ 2.40GHz, 2397.95 MHz
cpu0:
FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CFLUS
H,DS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE,SSE3,DTES64,MWAIT,DS-CPL,VMX,EST,TM
2,SSSE3,CX16,xTPR,PDCM,NXE,LONG,LAHF,PERF,SENSOR


Is that some error in eg++ (all software installed from pkg)?
How can this be fixed/avoided?


Here's the rest of the error message:

/usr/include/mmintrin.h: In function '__m64 _mm_sub_si64(__m64, __m64)':
/usr/include/mmintrin.h:416:72: error: cannot convert 'long long int' to
'__vector(1) long long int' for argument '1' to '__vector(1) long long int
__builtin_ia32_psubq(__vector(1) long long int, __vector(1) long long int)'
   return (__m64) __builtin_ia32_psubq ((long long)__m1, (long long)__m2);
^
/usr/include/mmintrin.h: In function '__m64 _mm_sll_pi16(__m64, __m64)':
/usr/include/mmintrin.h:523:71: error: cannot convert 'long long int' to
'__vector(4) short int' for argument '2' to '__vector(4) short int
__builtin_ia32_psllw(__vector(4) short int, __vector(4) short int)'
   return (__m64) __builtin_ia32_psllw ((__v4hi)__m, (long long)__count);
   ^
/usr/include/mmintrin.h: In function '__m64 _mm_slli_pi16(__m64, int)':
/usr/include/mmintrin.h:535:60: error: cannot convert 'int' to '__vector(4)
short int' for argument '2' to '__vector(4) short int
__builtin_ia32_psllw(__vector(4) short int, __vector(4) short int)'
   return (__m64) __builtin_ia32_psllw ((__v4hi)__m, __count);
^
/usr/include/mmintrin.h: In function '__m64 _mm_sll_pi32(__m64, __m64)':
/usr/include/mmintrin.h:548:71: error: cannot convert 'long long int' to
'__vector(2) int' for argument '2' to '__vector(2) int
__builtin_ia32_pslld(__vector(2) int, __vector(2) int)'
   return (__m64) __builtin_ia32_pslld ((__v2si)__m, (long long)__count);