Skip to content

botan: Bugfix Python build; use Python 3.14; Change name to botan2 - #33643

Closed
essandess wants to merge 3 commits into
macports:masterfrom
essandess:botan2
Closed

botan: Bugfix Python build; use Python 3.14; Change name to botan2#33643
essandess wants to merge 3 commits into
macports:masterfrom
essandess:botan2

Conversation

@essandess

Copy link
Copy Markdown
Contributor

Description

Type(s)
  • bugfix
  • enhancement
  • security fix
Tested on

macOS x.y
Xcode x.y / Command Line Tools x.y.z

Verification

Have you

  • followed our Commit Message Guidelines?
  • squashed and minimized your commits?
  • checked that there aren't other open pull requests for the same change?
  • referenced existing tickets on Trac with full URL in commit message?
  • checked your Portfile with port lint?
  • tried existing tests with sudo port test?
  • tried a full install with sudo port -vst install?
  • tested basic functionality of all binary files?
  • checked that the Portfile's most important variants haven't been broken?

@macportsbot

Copy link
Copy Markdown

Notifying maintainers:
@RJVB for port qca.

@RJVB

RJVB commented Jul 21, 2026

Copy link
Copy Markdown
Contributor

Can you be more elaborate and explain the changes?

  • last I tried, botan 2.19.5 built fine with Python 3.9 . With Python being only a build (rather, a configure) dependency, there should be no reason to depend on a fixed Python version but rather use some logic to find e.g. the minimal known-sufficient version. (I have a PortGroup for that, which could be contributed as more ports can benefit from it).
  • I don't see a port:botan3, and I think it should be designed to allow concurrent installation with Botan2, just like versions 1 and 2 can co-exist.

@essandess

Copy link
Copy Markdown
Contributor Author

@essandess

essandess commented Jul 21, 2026

Copy link
Copy Markdown
Contributor Author
  • last I tried, botan 2.19.5 built fine with Python 3.9 . With Python being only a build (rather, a configure) dependency, there should be no reason to depend on a fixed Python version but rather use some logic to find e.g. the minimal known-sufficient version. (I have a PortGroup for that, which could be contributed as more ports can benefit from it).

Please see the commit string and diff. Currently, port botan build is tied to Python 3.12, and error because there's a missing dependency on py312-standard-distutils. We want to update to the default Python version, and add this dependency. Also, Python 3.9 EOL'd in 2025.

  • I don't see a port:botan3, and I think it should be designed to allow concurrent installation with Botan2, just like versions 1 and 2 can co-exist.

See #33642. I agree, but I don't know how to write *_select ports. Let's get an up-to-date botan3 first and someone can add that capability later. Additionally, botan1 isn't a good model for co-existence, see its notes:

This legacy version of Botan should not be used for current software.
It exists on MacPorts only to support legacy software that can not
be updated to the current version of Botan.

@essandess

Copy link
Copy Markdown
Contributor Author

@RJVB I see that qca latest version 2.3.10 supports botan3. Would you please create a PR that updates to port using #33642?

@RJVB

RJVB commented Jul 22, 2026 via email

Copy link
Copy Markdown
Contributor

@RJVB

RJVB commented Jul 22, 2026 via email

Copy link
Copy Markdown
Contributor

@RJVB

RJVB commented Jul 22, 2026 via email

Copy link
Copy Markdown
Contributor

@essandess

Copy link
Copy Markdown
Contributor Author

I don't follow the py?-standard-distutils problem. I don't know that port yet, nor where it comes from or why it would be needed here, nor why it's missing for python 3.12 or why that would be an issue.

Please see https://trac.macports.org/ticket/74244#ticket

If botan3 breaks API and/or ABI and isn't designed to co-exist with v2, then the only proper solution IMHO is to do what has been done for many other ports …

Both ports create ${prefix}/bin/botan and a few other common files. The simplest thing to do at first is to declare the conflict, and add an appropriate overlay later if necessary. There's only a few ports that use botan anyway, and it's not clear to me that botan2 is of incidental interest beyond a legacy port now, like botan1.

Thank you for your other comments, I've implemented the changes in the commits.

@essandess

Copy link
Copy Markdown
Contributor Author

I see that botan3 requires C++20. That may justify some reflection on backwards compatibility with older Darwin versions!

Patches for older systems have already been added. See: #33642 (review)

@RJVB

RJVB commented Jul 22, 2026 via email

Copy link
Copy Markdown
Contributor

@RJVB

RJVB commented Jul 22, 2026 via email

Copy link
Copy Markdown
Contributor

@RJVB

RJVB commented Jul 23, 2026 via email

Copy link
Copy Markdown
Contributor

@essandess

Copy link
Copy Markdown
Contributor Author

@RJVB I avoided a botan3 conflict as you suggested by moving a few files around.

@RJVB

RJVB commented Jul 24, 2026

Copy link
Copy Markdown
Contributor

I'd have just renamed the executable from botan to botan2, makes it easier to find if anyone needs it (idem for the manpage, and a bit less easy to forget to remove if it turns out there is no point in keeping it).

I see you get manpage. I missed that because it is in fact generated only if the configure step finds an rst2man executable on the path as there is on Linux. I'm not at my Mac right now but I would be surprised if there's a system rst2man? If there isn't, the rule on here is that you either disable the generation (--disable-rst2man) or add a dependency to the port providing the utility. That's tricky in this case as it's provided by py-docutils and you would probably have to patch the build system so it will search for rst2man-x.y. The same applies for sphinx-build, used for creating the handbook.

@barracuda156

Copy link
Copy Markdown
Contributor

I see that botan3 requires C++20. That may justify some reflection on backwards compatibility with older Darwin versions!

Patches for older systems have already been added. See: #33642 (review)

@essandess Just to be clear: my patches fix some legacy macOS-related issues and allow a working build on powerpc, but they do not address C++ standard at all: we use the latest GCC on powerpc, there is no problem there with C++20 or C++23. However older x86 that use libc++ and clang may have issues with modern C++.

@RJVB

RJVB commented Jul 24, 2026 via email

Copy link
Copy Markdown
Contributor

@barracuda156

Copy link
Copy Markdown
Contributor

@essandess

Copy link
Copy Markdown
Contributor Author

@RJVB

RJVB commented Jul 28, 2026 via email

Copy link
Copy Markdown
Contributor

@essandess

Copy link
Copy Markdown
Contributor Author

The commits from this PR have been incorporated into #33642.

@essandess essandess closed this Aug 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

maintainer: open Affects an openmaintainer port

Development

Successfully merging this pull request may close these issues.

4 participants