Sunday, April 15, 2018

Re: UPDATE: x11/qt4 (clang6)

On Sat Apr 14, 2018 at 03:44:32PM +0300, Pavel Korovin wrote:
> Dear all,
>
> Please find the diff for x11/qt4 attached.
> Quick-fix for build with clang6.
>
> --
> With best regards,
> Pavel Korovin

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/x11/qt4/Makefile,v
> retrieving revision 1.151
> diff -u -p -r1.151 Makefile
> --- Makefile 20 Jan 2018 14:03:39 -0000 1.151
> +++ Makefile 14 Apr 2018 12:37:00 -0000
> @@ -25,13 +25,13 @@ PKGNAME-main = qt4-${PKGVERSION}
> PKGNAME-debug = qt4-debug-${PKGVERSION}
> FULLPKGNAME-html = qt4-html-${PKGVERSION}
> FULLPKGPATH-html = ${BASE_PKGPATH},-html
> -REVISION-main = 14
> -REVISION-mysql = 2
> -REVISION-postgresql = 2
> -REVISION-sqlite2 = 2
> -REVISION-tds = 2
> -REVISION-debug = 1
> -REVISION-examples = 3
> +REVISION-main = 15
> +REVISION-mysql = 3
> +REVISION-postgresql = 3
> +REVISION-sqlite2 = 3
> +REVISION-tds = 3
> +REVISION-debug = 2
> +REVISION-examples = 4
> REVISION-html = 0
>
> # XXX qmake include parser is bogus
> @@ -119,7 +119,6 @@ CONFIGURE_ARGS += -I${LOCALBASE}/include
> CONFIGURE_ARGS += -I${LOCALBASE}/include/postgresql \
> -I${LOCALBASE}/include/postgresql/server \
> -plugin-sql-psql
> -CONFIGURE_ARGS += -platform openbsd-g++4
>
> # XXX make sure those libraries gets written to libQtGui.la
> QMAKE_LIBS_GUI = freetype SM ICE Xi Xrender Xinerama fontconfig Xext X11
> @@ -242,8 +241,16 @@ MAKE_FLAGS += LIB$l_VERSION=$v
>
> DESTDIRNAME = INSTALL_ROOT
>
> +.include <bsd.port.arch.mk>
> +.if ${PROPERTIES:Mclang}
> +CONFIGURE_ARGS += -platform openbsd-clang
> +.else
> +CONFIGURE_ARGS += -platform openbsd-g++4
> +.endif
> +
> pre-patch:
> cd ${WRKDIST} && cp -R mkspecs/openbsd-g++ mkspecs/openbsd-g++4
> + cd ${WRKDIST} && cp -R mkspecs/openbsd-g++ mkspecs/openbsd-clang

PLIST update is required!

$ ls -la /usr/local/lib/qt4/mkspecs/
lrwxr-xr-x 1 root wheel 13 Apr 15 12:56 default -> openbsd-clang

Otherwise Qt4 builds fine with clang6

No comments:

Post a Comment