pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: qcad can't read/import DXF files.
On Thu, 7 Nov 2019, John D. Baker wrote:
> The same behavior is seen with intermediate libraries "libqcadentity.so"
> and "libqcadoperations.so". First built in release mode, then deleted and
> built in debug mode. The debug mode result is then used in subsequent
> linkages, including "libqcaddxf.so". Apparently, only "libdxflib.so"
> linkages trip the plugin loader to complain about release plugin built
> in debug mode.
Or so I thought. I built it again with my usual MAKE_JOBS setting but
with my SUBST group for debug-mode "libdxflib.so". The resulting
"libqcaddxf.so" was again rejected as being "release plugin built in
debug mode".
So, I've expanded the SUBST group to include debug-mode builds for
"libqcadentity.so" and "libqcadoperations.so" as they are also linked
in when building "libqcaddxf.so". Curiously, the build system uses
separate "release" and "debug" subdirectories for the individual object
files that make up these intermediate libraries, but always produces
just the one shared library--first in release mode, deletes it, then in
debug mode.
(All the other objects linked to form "libqcaddxf.so" are built into
separate "release" and "debug" subdirectories, so the correct version
is always used. The build system does produce the release version as
"libqcaddxf.so" and the debug version as "libqcaddxf_debug.so".)
A real fix would be to get the configure system that generates the
Makefiles to always produce "lib*_debug.so" files in debug mode and
to reference those when linking debug-mode versions of other libraries.
I don't grok the qt way of things, though (nor see how to submit an
upstream bug report).
+Index: cad/qcad/Makefile
+===================================================================
+RCS file: /cvsroot/pkgsrc/cad/qcad/Makefile,v
+retrieving revision 1.77
+diff -u -p -r1.77 Makefile
+--- cad/qcad/Makefile 19 Sep 2019 21:59:36 -0000 1.77
++++ cad/qcad/Makefile 8 Nov 2019 17:28:10 -0000
+@@ -27,6 +27,16 @@ SUBST_FILES.paths+= scripts/Help/ShowRea
+ SUBST_FILES.paths+= scripts/Widgets/LibraryBrowser/LibraryBrowser.js
+ SUBST_VARS.paths= PREFIX
+
++# Don't build intermediate libraries with the same name in debug mode as
++# in release-mode.
++SUBST_CLASSES+= dbgmode
++SUBST_STAGE.dbgmode= post-configure
++SUBST_MESSAGE.dbgmode= Debug mode: lib*.so -> lib*_debug.so
++SUBST_FILES.dbgmode= src/3rdparty/dxflib/Makefile.Debug
++SUBST_FILES.dbgmode+= src/entity/Makefile.Debug
++SUBST_FILES.dbgmode+= src/operations/Makefile.Debug
++SUBST_SED.dbgmode= -e 's,\(lib..*\)\(\.so\),\1_debug\2,g'
++
+ AUTO_MKDIRS= yes
+
+ #
--
|/"\ John D. Baker, KN5UKS NetBSD Darwin/MacOS X
|\ / jdbaker[snail]consolidated[flyspeck]net OpenBSD FreeBSD
| X No HTML/proprietary data in email. BSD just sits there and works!
|/ \ GPGkeyID: D703 4A7E 479F 63F8 D3F4 BD99 9572 8F23 E4AD 1645
Home |
Main Index |
Thread Index |
Old Index