]> granicus.if.org Git - graphviz/commitdiff
Add --tag=CC when compiling quartz plugin
authorRyan Schmidt <gitlab@ryandesign.com>
Sat, 8 May 2021 14:11:01 +0000 (14:11 +0000)
committerMatthew Fernandez <matthew.fernandez@gmail.com>
Wed, 2 Jun 2021 00:32:34 +0000 (17:32 -0700)
Edit by Matthew Fernandez: When compiling libraries, libtool infers a so called
“tag” indicating the language model it should use when creating objects.
The libtool docs¹ claim `CC` is inferred when no tag is explicitly given, but
empirically this does not seem to be true. On macOS, some versions of libtool
give up when seeing a .m file with the error:

  libtool: compile: unable to infer tagged configuration
  libtool:   error: specify a tag with '--tag'

To fix this, we now explicitly set the `CC` tag. Note that this is not guarded
to be macOS-only because this action needs to be taken in all environments with
Objective-C support that are building the Quartz plugin (if this is in fact
possible on anything other than macOS).

This commit also fixes a further problem where AM_LIBTOOLFLAGS was misspelled
as AM_LIBTOOLSFLAGS. It looks like 79aa7d77ef433d66c0142168d2817b4c7014d263
previously tried to fix this same problem but (1) the WITH_DARWIN9 guard is
insufficient for recent macOS versions and (2) the typo made this whole change
a no-op.

This issue was reported by downstream Macports users.

Fixes #2065.

¹ https://www.gnu.org/software/libtool/manual/html_node/Tags.html

CHANGELOG.md
plugin/quartz/Makefile.am

index 7051e6526561297c74640c7fd1d3d65d6ec28e73..f729bcd06a8ec700c11f7f815b60a711e28d1100 100644 (file)
@@ -14,6 +14,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
 ### Fixed
 
 - no longer pass libcommon to the linker twice in mm2gv when building with CMake
+- Quartz plugin is now compiled with explicit `--tag=CC` to libtool #2065
 
 ## [2.47.2] - 2021-05-26
 
index 71b8b1c2c8e1cf717795b72c4b9f1495bea25b80..ac97bfe60268de7913988046d059ca71b2a62fd1 100644 (file)
@@ -38,5 +38,6 @@ endif
 
 if WITH_DARWIN9
 libgvplugin_quartz_la_LDFLAGS += -Wl,-exported_symbol,_gvplugin_quartz_LTX_library
-AM_LIBTOOLSFLAGS = --tag=CC
 endif
+
+AM_LIBTOOLFLAGS = --tag=CC