<feed xmlns='http://www.w3.org/2005/Atom'>
<title>unit.git/auto/otel, branch 1.34.1-1</title>
<subtitle>Universal Web Application Server</subtitle>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/unit.git/'/>
<entry>
<title>auto/otel: don't look for OpenSSL on Darwin</title>
<updated>2025-01-10T21:01:46+00:00</updated>
<author>
<name>Konstantin Pavlov</name>
<email>thresh@nginx.com</email>
</author>
<published>2024-12-20T00:09:43+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/unit.git/commit/?id=6980ac17650487a83a7645594dc5f132ee618243'/>
<id>6980ac17650487a83a7645594dc5f132ee618243</id>
<content type='text'>
Rust code relies on macOS-provided frameworks for TLS.

Fixes: 9d3dcb800 ("otel: add build tooling to include otel code")
[ Tweaked subject prefix. Some minor tweaks for current changes. -
  Andrew ]
Signed-off-by: Andrew Clayton &lt;a.clayton@nginx.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Rust code relies on macOS-provided frameworks for TLS.

Fixes: 9d3dcb800 ("otel: add build tooling to include otel code")
[ Tweaked subject prefix. Some minor tweaks for current changes. -
  Andrew ]
Signed-off-by: Andrew Clayton &lt;a.clayton@nginx.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>auto/otel: Make use of nxt_feature_name</title>
<updated>2025-01-10T21:01:46+00:00</updated>
<author>
<name>Andrew Clayton</name>
<email>a.clayton@nginx.com</email>
</author>
<published>2024-12-19T23:51:59+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/unit.git/commit/?id=78489c9d2bcc9a124d942fdfb5530fc377417b9e'/>
<id>78489c9d2bcc9a124d942fdfb5530fc377417b9e</id>
<content type='text'>
When building with --otel on macOS for example I was seeing compile
failures with the cpu_set_t stuff which should only be used under Linux.

It turned out that despite

  checking for Linux sched_getaffinity() ... not found

we were getting

  #ifndef NXT_HAVE_LINUX_SCHED_GETAFFINITY
  #define NXT_HAVE_LINUX_SCHED_GETAFFINITY  1
  #endif

in build/include/nxt_auto_config.h

It seems this was due to the

    . auto/feature

in auto/otel, this check happens right after the above. Without having

    nxt_feature_name=NXT_HAVE_OTEL

set.

Instead we were adding the define for that manually.

Doing auto/feature without having a nxt_feature_name must have used the
last set one and enabled it.

Set nxt_feature_name and remove the manual editing of nxt_auto_config.h

Fixes: 9d3dcb800 ("otel: add build tooling to include otel code")
Signed-off-by: Andrew Clayton &lt;a.clayton@nginx.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
When building with --otel on macOS for example I was seeing compile
failures with the cpu_set_t stuff which should only be used under Linux.

It turned out that despite

  checking for Linux sched_getaffinity() ... not found

we were getting

  #ifndef NXT_HAVE_LINUX_SCHED_GETAFFINITY
  #define NXT_HAVE_LINUX_SCHED_GETAFFINITY  1
  #endif

in build/include/nxt_auto_config.h

It seems this was due to the

    . auto/feature

in auto/otel, this check happens right after the above. Without having

    nxt_feature_name=NXT_HAVE_OTEL

set.

Instead we were adding the define for that manually.

Doing auto/feature without having a nxt_feature_name must have used the
last set one and enabled it.

Set nxt_feature_name and remove the manual editing of nxt_auto_config.h

Fixes: 9d3dcb800 ("otel: add build tooling to include otel code")
Signed-off-by: Andrew Clayton &lt;a.clayton@nginx.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>auto/otel: Remove pkg-config check</title>
<updated>2024-12-13T17:22:01+00:00</updated>
<author>
<name>Andrew Clayton</name>
<email>a.clayton@nginx.com</email>
</author>
<published>2024-12-13T17:06:53+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/unit.git/commit/?id=ae20ab0a3b2b90b471e868905dd44d7b75501fd0'/>
<id>ae20ab0a3b2b90b471e868905dd44d7b75501fd0</id>
<content type='text'>
@thresheek reported an issue trying to configure OTEL support on Amazon
Linux 2

  checking for OTEL requirements:
    - checking for rust compiler ... found
    - checking for cargo ... found
    - checking for OpenSSL library ... found
  Package openssl was not found in the pkg-config search path.
  Perhaps you should add the directory containing `openssl.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'openssl' found

We successfully built the test program with '-lssl -lcrypto', but then
tried to use 'pkg-config openssl --cflags --libs' to override
NXT_OTEL_LIBS.

On Amazon Linux2 there is no openssl.pc, they have a openssl11.pc.

Let's just remove the pkg-config check, if we get here, we have
successfully built with '-lssl -lcrypto', so just go with that (it also
matches what we do in auto/ssltls).

Reported-by: Konstantin Pavlov &lt;thresh@nginx.com&gt;
Closes: https://github.com/nginx/unit/issues/1510
Signed-off-by: Andrew Clayton &lt;a.clayton@nginx.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
@thresheek reported an issue trying to configure OTEL support on Amazon
Linux 2

  checking for OTEL requirements:
    - checking for rust compiler ... found
    - checking for cargo ... found
    - checking for OpenSSL library ... found
  Package openssl was not found in the pkg-config search path.
  Perhaps you should add the directory containing `openssl.pc'
  to the PKG_CONFIG_PATH environment variable
  No package 'openssl' found

We successfully built the test program with '-lssl -lcrypto', but then
tried to use 'pkg-config openssl --cflags --libs' to override
NXT_OTEL_LIBS.

On Amazon Linux2 there is no openssl.pc, they have a openssl11.pc.

Let's just remove the pkg-config check, if we get here, we have
successfully built with '-lssl -lcrypto', so just go with that (it also
matches what we do in auto/ssltls).

Reported-by: Konstantin Pavlov &lt;thresh@nginx.com&gt;
Closes: https://github.com/nginx/unit/issues/1510
Signed-off-by: Andrew Clayton &lt;a.clayton@nginx.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>otel: add build tooling to include otel code</title>
<updated>2024-11-12T17:50:02+00:00</updated>
<author>
<name>Ava Hahn</name>
<email>a.hahn@f5.com</email>
</author>
<published>2024-11-07T22:14:28+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/unit.git/commit/?id=9d3dcb800aba0c036b032ccd00197712c3f5d0d9'/>
<id>9d3dcb800aba0c036b032ccd00197712c3f5d0d9</id>
<content type='text'>
Adds the --otel flag to the configure command and the various build time
variables and checks that are needed in this flow.

It also includes the nxt_otel.c and nxt_otel.h files that are needed for
the rest of Unit to talk to the compiled static library that's generated
from the rust crate.

Signed-off-by: Ava Hahn &lt;a.hahn@f5.com&gt;
Co-authored-by: Gabor Javorszky &lt;g.javorszky@f5.com&gt;
Signed-off-by: Gabor Javorszky &lt;g.javorszky@f5.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Adds the --otel flag to the configure command and the various build time
variables and checks that are needed in this flow.

It also includes the nxt_otel.c and nxt_otel.h files that are needed for
the rest of Unit to talk to the compiled static library that's generated
from the rust crate.

Signed-off-by: Ava Hahn &lt;a.hahn@f5.com&gt;
Co-authored-by: Gabor Javorszky &lt;g.javorszky@f5.com&gt;
Signed-off-by: Gabor Javorszky &lt;g.javorszky@f5.com&gt;
</pre>
</div>
</content>
</entry>
</feed>
