Am 06.02.25 um 18:18 schrieb Darryl Baker:
> My question is why is tomcat-native dependent on APR at all? Could it be built without that dependency?

The APR library originates in the Apache httpd project. The project decided long ago, to split out some very basic functionality into a separate library trying to encapsulate OS specific code in it. This library is called APR (Apache Portable Runtime) or libapr. A second one is celled APR Util (APR Utilities or libapr-util) which contains higher level code but is not relevant to tcnative.

The tcnative library contains functionality that hooks into Tomcat and uses some the APR library as an implementation of its lower level functionality.

In order to use tcnative (confusingly sometimes also called the APR connector) inside Tomcat you need both, the tcnative library and the APR library.

And to build tcnative yourself you also need the APR library and its header files (the devel package) plus OpenSSL and its header files.

Since APR is much older and also needed by the Apache httpd web server, most Linux distributions provide the APR library binaries (and header files) in the form of a distribution package. So you do not need to build this by yourself, just install it.

Many distributions do not provide packages for tcnative, so you do need to build it yourself.

> Can I build tomcat native on Rocky Linux? Then could I use it on Red Hat? Has anyone tried that?

Currently RHEL and Rocky are binary compatible assuming that you are using the same versions of them. You can build your binary on any of those and use it on the other one.

Best regards,

Rainer

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tomcat.apache.org
For additional commands, e-mail: users-h...@tomcat.apache.org

Reply via email to