From nobody Sun Sep 24 04:54:48 2023 X-Original-To: ports-bugs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4RtYZx21mbz4t4rt for ; Sun, 24 Sep 2023 04:54:49 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4RtYZw6b0cz3J2N for ; Sun, 24 Sep 2023 04:54:48 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1695531288; a=rsa-sha256; cv=none; b=jWV12i+/990xGz2rWUEcQ+wZprW2HRioC8ACNcjpd054yVwBvhpoBPaqDJ5AmoXNrwgAMq qC1fWFg81NS7+DYyFfrfseQw1y3FpizVyz14r46BEhSKvEgxsK4PRU1wOPU0R+mFjzYgiA uIYOrm2mlB5iZahggI3+Oxnb9O6xPYBU8dUgnLZyPYF3/xuxKuMYIB5JRuTpJgFUYeb3fx I+2BeKaWA80uA6FM3Pu7wHe5OSWGGoTCk8f8PJQXeCAdBJXs73XHRh4Ji8mB0XcGKIm0aJ TWEb/Nb9aTDxOfe7shcxaMxbWQckuAfxKoGXlllxYlTfpUVoQjDtFnNrg4F1lQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1695531288; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=8Et1qgNFQQ9xtVTGhzsWP15bGLMWRAcxeoUyyFEr6qQ=; b=to9L2M4bMU8cZKcGpbCKCDpujWCgFKFibe6qK7KkDaAu1NBPXnmvc72GeekTaXu8DjC2Pz QGFvYOcNR4fUwd/h8XxeTzvw/KY0HwaCiSHVtB6hzbPcaG5QsZL767jo4iL+Ru8kTNcZqO 27hbXZsTIYZD8Z1jThFILm9fxcl3D+TPaymNHTF+u5TaOkhgu1Y+vi64NXpKPFl37b6GQk kAuIDBRy3w6u81cwfVyvrWroWvI8QeCaJ/u5ZjD5MGBK+i/EWTf9FX8aWcvF/h5f6j/icc t6ccHEsYYq5u9tp8u9zCjGQKl4dn11Yv9yAN/12/yk1iT03GN4qMC2SqfoJctw== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4RtYZw5XbkzYgl for ; Sun, 24 Sep 2023 04:54:48 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 38O4smsx093378 for ; Sun, 24 Sep 2023 04:54:48 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 38O4smJR093377 for ports-bugs@FreeBSD.org; Sun, 24 Sep 2023 04:54:48 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 274061] graphics/gdal Fix TILEDB knob, tame a bit of overzealous cmake auto-feature creep for good measure Date: Sun, 24 Sep 2023 04:54:48 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: alt2600@icloud.com X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: sunpoet@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter flagtypes.name attachments.created Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Ports bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-ports-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-ports-bugs@freebsd.org X-BeenThere: freebsd-ports-bugs@freebsd.org MIME-Version: 1.0 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D274061 Bug ID: 274061 Summary: graphics/gdal Fix TILEDB knob, tame a bit of overzealous cmake auto-feature creep for good measure Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: Individual Port(s) Assignee: sunpoet@FreeBSD.org Reporter: alt2600@icloud.com Flags: maintainer-feedback?(sunpoet@FreeBSD.org) Assignee: sunpoet@FreeBSD.org Created attachment 245176 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D245176&action= =3Dedit git-fixtiledb-tamecmake.diff amd64 13.2, live system building With the update to tiledb the knob broke in gdal with the following error during the tiledb module build FAILED: frmts/tiledb/CMakeFiles/gdal_TileDB.dir/tiledbcommon.cpp.o=20 /usr/bin/c++ -DDONT_DEPRECATE_SPRINTF -DGDAL_COMPILATION -DTILEDB_DEPRECATE= D=3D"" -I/usr/ports/graphics/gdal/work/gdal-3.7.2/apps -I/usr/ports/graphics/gdal/work/gdal-3.7.2/alg -I/usr/ports/graphics/gdal/work/gdal-3.7.2/gcore -I/usr/ports/graphics/gdal/work/.build/gcore -I/usr/ports/graphics/gdal/work/gdal-3.7.2/port -I/usr/ports/graphics/gdal/work/.build/port -I/usr/ports/graphics/gdal/work/gdal-3.7.2/ogr -I/usr/ports/graphics/gdal/work/gdal-3.7.2/ogr/ogrsf_frmts -I/usr/ports/graphics/gdal/work/gdal-3.7.2/frmts -O2 -pipe -march=3Dwestmer= e=20 -DInt64=3Duint64_t -DLIBICONV_PLUG -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing -DLIBICONV_PLUG -isystem /usr/local/include -std=3Dc++17 -fno-finite-math-only -fvisibility=3Dhidden= -O2 -pipe -march=3Dwestmere -DInt64=3Duint64_t -DLIBICONV_PLUG -fstack-protector-strong -isystem /usr/local/include -fno-strict-aliasing= =20=20 -DLIBICONV_PLUG -isystem /usr/local/include -std=3Dc++17 -DNDEBUG -std=3Dc= ++17 -flto=3Dthin -fPIC -Wall -Wextra -Winit-self -Wunused-parameter -Wmissing-declarations -Wshorten-64-to-32 -Wshadow -Wshadow-field -Wmissing-include-dirs -Wformat -Werror=3Dformat-security -Wno-format-nonli= teral -Werror=3Dvla -Wdate-time -Wnull-dereference -Wextra-semi -Wcomma -Wfloat-conversion -Wdocumentation -Wno-documentation-deprecated-sync -Wunused-private-field -Wnon-virtual-dtor -Woverloaded-virtual -Wsuggest-override -fno-operator-names -Wzero-as-null-pointer-constant -MD = -MT frmts/tiledb/CMakeFiles/gdal_TileDB.dir/tiledbcommon.cpp.o -MF frmts/tiledb/CMakeFiles/gdal_TileDB.dir/tiledbcommon.cpp.o.d -o frmts/tiledb/CMakeFiles/gdal_TileDB.dir/tiledbcommon.cpp.o -c /usr/ports/graphics/gdal/work/gdal-3.7.2/frmts/tiledb/tiledbcommon.cpp In file included from /usr/ports/graphics/gdal/work/gdal-3.7.2/frmts/tiledb/tiledbcommon.cpp:29: In file included from /usr/ports/graphics/gdal/work/gdal-3.7.2/frmts/tiledb/tiledbheaders.h:50: In file included from /usr/local/include/tiledb/tiledb:49: In file included from /usr/local/include/tiledb/array.h:38: In file included from /usr/local/include/tiledb/array_schema.h:38: In file included from /usr/local/include/tiledb/attribute.h:38: In file included from /usr/local/include/tiledb/context.h:38: In file included from /usr/local/include/tiledb/config.h:39: In file included from /usr/local/include/tiledb/utils.h:36: In file included from /usr/local/include/tiledb/exception.h:39: /usr/local/include/tiledb/type.h:51:9: error: token is not a valid binary operator in a preprocessor subexpression #if not defined(__clang__) && __GNUG__ && __GNUC__ < 5 ~~~ ^ 1 error generated. after stubbing the pre-processor code into a test stub file and trying all = the compile options until the error stopped it building I found it was because cmake compiler checks included in gdal explicitly auto enable this flag if supported by the compiler -fno-operator-names . this is a problem because tiledb type.h above uses not instead of ! to fix an issue for old gcc versi= ons, and that flag explicitly dis-allows using not over !. after fighting with c= make I eventually found TILEDB_CMAKE_BOOL_OFF=3D HAVE_FLAG_NO_OPERATOR_NAMES to disable that check when tiledb is turned on and it now builds, and things l= ike qgis use it fine. Gdal upstream should likely disable that check entirely if they want to support tiledb, I have no idea why a person would want that on, unless its a standards thing, then maybe tiledb should change their header,= but maybe can't given its for an old gcc version, I don't know. Given how many times I ran make clean configure i noticed a few other greedy checks and so found was to tame them. Basically disabling finding swig, python, jni, and = java given no bindings are listed, and it could cause issues given it doesn't necessarily find the default python anyway, since python.mk is never invoke= d. Quality of life for live system ports builders to get closer to pkg repo builds, though I tried some of these first as my initial thought was python 3.10 instead of 3.9 being found was somehow breaking the TILEDB knob, but it appears unrelated. I think it will lead to wild and painful debugging should someone stumble onto unregistered dependencies breaking their builds or hav= ing unpredictable builds because of cmake greed. #On live system builds, triggers potential PR 262109 issue if swig is found= , by also calling FindPython routines.=20 #If python alone is found it also triggers the issue. Disable explicitly for consistent builds given no bindings are built here, as well as jni/java for good measure CMAKE_ARGS+=3D -DCMAKE_DISABLE_FIND_PACKAGE_SWIG:BOOL=3Dtrue -DCMAKE_DISABLE_FIND_PACKAGE_Python:BOOL=3Dtrue -DCMAKE_DISABLE_FIND_PACKAGE_JNI:BOOL=3Dtrue -DCMAKE_DISABLE_FIND_PACKAGE_Java:BOOL=3Dtrue I also found that Jpeg-XL is greedily added in, but at least it seems to be= an option maybe a knob can be added for GDAL_USE_JXL, I didn't disable at this time as it wasn't causing issues, when it breaks I'll post a patch for the knob. I figured that would require a PORTREVISION. I also found that it see= ms to automatically be doing LTO, but likely this is going to happen with the = repo builds too as it is likely just a compiler check. Unlike tiledb, its AVX ch= ecks do not seem to auto add AVX compiler flags, or maybe just lucky this isn't doing much vector math. cmake is a wild build system. anyway, TILEDB knob is now working again with the posted patch. I think limiting the scope of cmake's wild finds is a good idea too, but you can ch= ose to use or not use as you see fit. Not sure if technically turning off python finding should be a PORTREVISION, but since Swig wouldn't be there, I don't think it would be doing any python in the port. --=20 You are receiving this mail because: You are the assignee for the bug.=