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:

> Since the Makefiles are generated during the "configure" phase, there
> would probably have to be a "post-configure" SUBST group to automate
> this fix.
> 
> Also, I'll see what the minimum fix necessary is--just "libdxflib.so"
> or if the other libraries (libqcadentity.so, libqcadoperations.so) really
> need to be done the same way.

I tried just deleting or commenting out the "debug" subtarget in the master
Makefile for libdxflib.so, but it still built debug mode anyway.

The process is racy and there's no guarantee which will be built last,
debug or release mode.  I got lucky a couple of times and release mode
was built last.

Instead, I forced the Makefile.Debug to name its target "libdxflib_debug.so"
to match other such libraries.  If someone really wants to do a debug
build of qcad, other stuff will need to be adjusted.

The "libqcadentities.so" and "libqcadoperations.so" libraries seem to
either build release mode last consistently or don't trip up the plugin
loader if the debug mode version is linked in.

My patch:

+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	7 Nov 2019 15:35:45 -0000
+@@ -27,6 +27,12 @@ SUBST_FILES.paths+=	scripts/Help/ShowRea
+ SUBST_FILES.paths+=	scripts/Widgets/LibraryBrowser/LibraryBrowser.js
+ SUBST_VARS.paths=	PREFIX
+ 
++SUBST_CLASSES+=		dbgmode
++SUBST_STAGE.dbgmode=	post-configure
++SUBST_MESSAGE.dbgmode=	Debug mode: libdxflib.so -> libdxflib_debug.so
++SUBST_FILES.dbgmode=	src/3rdparty/dxflib/Makefile.Debug
++SUBST_SED.dbgmode=	-e 's,libdxflib,&_debug,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