<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN" "http://www.w3.org/TR/REC-html40/loose.dtd">
<html lang="en">
<head>
<meta content="text/html; charset=US-ASCII" http-equiv="Content-Type">
<title>
GitLab
</title>


<style>img {
max-width: 100%; height: auto;
}
</style>
</head>
<body>
<div class="content">

<p class="details" style="font-style: italic; color: #777;">
<a href="https://gitlab.com/alebcay">Caleb Xu</a> created an issue:
</p>
<div></div>
<h2 dir="auto">
<a id="user-content-description-of-problem" class="anchor" href="#description-of-problem" aria-hidden="true"></a>Description of problem:</h2>
<p dir="auto">Building <code>gnutls</code> 3.6.9 fails on macOS Sierra with error:</p>
<pre class="code highlight js-syntax-highlight plaintext" lang="plaintext" v-pre="true"><code><span id="LC1" class="line" lang="plaintext">Undefined symbols for architecture x86_64:</span>
<span id="LC2" class="line" lang="plaintext">  "___get_cpuid_count", referenced from:</span>
<span id="LC3" class="line" lang="plaintext">  _register_x86_crypto in libaccelerated.a(x86-common.o)</span></code></pre>
<h2 dir="auto">
<a id="user-content-version-of-gnutls-used" class="anchor" href="#version-of-gnutls-used" aria-hidden="true"></a>Version of gnutls used:</h2>
<p dir="auto">3.6.9</p>
<h2 dir="auto">
<a id="user-content-distributor-of-gnutls-eg-ubuntu-fedora-rhel" class="anchor" href="#distributor-of-gnutls-eg-ubuntu-fedora-rhel" aria-hidden="true"></a>Distributor of gnutls (e.g., Ubuntu, Fedora, RHEL)</h2>
<p dir="auto">From source tarball, testing in CI for updating the Homebrew package manager with <code>gnutls</code> 3.6.9. Associated change on the Homebrew side: <a href="https://github.com/Homebrew/homebrew-core/pull/42779" rel="nofollow noreferrer noopener" target="_blank">https://github.com/Homebrew/homebrew-core/pull/42779</a></p>
<h2 dir="auto">
<a id="user-content-how-reproducible" class="anchor" href="#how-reproducible" aria-hidden="true"></a>How reproducible:</h2>
<p dir="auto">Steps to Reproduce:</p>
<ul dir="auto">
<li>Download and unpack 3.6.9 tarball (<a href="https://www.gnupg.org/ftp/gcrypt/gnutls/v3.6/gnutls-3.6.9.tar.xz" rel="nofollow noreferrer noopener" target="_blank">https://www.gnupg.org/ftp/gcrypt/gnutls/v3.6/gnutls-3.6.9.tar.xz</a>)</li>
<li><code>./configure --disable-dependency-tracking --disable-silent-rules --disable-static --prefix=#{prefix} --sysconfdir=#{etc} --with-default-trust-store-file=#{etc}/openssl/cert.pem --disable-guile --disable-heartbeat-support --with-p11-kit</code></li>
<li><code>make install</code></li>
</ul>
<h2 dir="auto">
<a id="user-content-actual-results" class="anchor" href="#actual-results" aria-hidden="true"></a>Actual results:</h2>
<pre class="code highlight js-syntax-highlight plaintext" lang="plaintext" v-pre="true"><code><span id="LC1" class="line" lang="plaintext">Undefined symbols for architecture x86_64:</span>
<span id="LC2" class="line" lang="plaintext">  "___get_cpuid_count", referenced from:</span>
<span id="LC3" class="line" lang="plaintext">  _register_x86_crypto in libaccelerated.a(x86-common.o)</span></code></pre>
<h2 dir="auto">
<a id="user-content-expected-results" class="anchor" href="#expected-results" aria-hidden="true"></a>Expected results:</h2>
<p dir="auto">Successful compilation.</p>
<hr>
<p dir="auto">Based on my limited understanding from googling this particular error, it seems that the symbol in question was added into <code>clang</code> starting in <code>llvm</code> 5.0.0. macOS Sierra ships with a toolchain derived from <code>llvm</code> 4.0.0, so the symbol is not available.</p>
<p dir="auto">I have attempted to use <code>gcc</code> to build it instead, but <code>gcc</code> does not seem to like some of the macOS Security framework that <code>gnutls</code> links against:</p>
<pre class="code highlight js-syntax-highlight plaintext" lang="plaintext" v-pre="true"><code><span id="LC1" class="line" lang="plaintext">In file included from /System/Library/Frameworks/Security.framework/Headers/AuthSession.h:32,</span>
<span id="LC2" class="line" lang="plaintext">                 from /System/Library/Frameworks/Security.framework/Headers/Security.h:43,</span>
<span id="LC3" class="line" lang="plaintext">                 from system/certs.c:49:</span>
<span id="LC4" class="line" lang="plaintext">/System/Library/Frameworks/Security.framework/Headers/Authorization.h:192:7: error: variably modified 'bytes' at file scope</span>
<span id="LC5" class="line" lang="plaintext">  192 |  char bytes[kAuthorizationExternalFormLength];</span>
<span id="LC6" class="line" lang="plaintext">      |       ^~~~~</span></code></pre>

</div>
<div class="footer" style="margin-top: 10px;">
<p style="font-size: small; color: #777;">

<br>
Reply to this email directly or <a href="https://gitlab.com/gnutls/gnutls/issues/816">view it on GitLab</a>.
<br>
You're receiving this email because of your account on gitlab.com.
If you'd like to receive fewer emails, you can
<a href="https://gitlab.com/sent_notifications/ba3768e2d26a25d5600302420758474b/unsubscribe">unsubscribe</a>
from this thread or
adjust your notification settings.
<script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","action":{"@type":"ViewAction","name":"View Issue","url":"https://gitlab.com/gnutls/gnutls/issues/816"}}</script>


</p>
</div>
</body>
</html>