Opened 11 years ago

Closed 10 years ago

#39635 closed enhancement (fixed)

botan: add Python dependency and universal variant

Reported by: macports@… Owned by: mww@…
Priority: Normal Milestone:
Component: ports Version: 2.1.3
Keywords: haspatch Cc: MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)
Port: botan

Description

botan's configure script is written in Python, so we need an explicit build dependency. On IRC, jmr_mp and neverpanic both suggested adding a hard-coded dependency on python27 instead of a set of variants for different possible Python versions.

Moreover, since qt4-creator-mac +universal requires botan +universal, here's an attempt to enable a universal variant for botan.

Attachments (2)

muniversal-botan-patch.diff (1.2 KB) - added by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez) 11 years ago.
botan-python-universal.patch (2.8 KB) - added by macports@… 10 years ago.
Updated patch v3

Download all attachments as: .zip

Change History (12)

comment:1 Changed 11 years ago by macports@…

This patch should fix #39451.

comment:2 Changed 11 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

I do not know much about how botan works, but wouldn't disabling optimizations slow it down?

    configure.args-append --disable-asm --enable-modules=mp_generic \
                          --disable-modules=mp_x86_32,mp_x86_64,rdrand

The muniversal PortGroup was designed for just this problem.
Attached is another possible solution.

Changed 11 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Attachment: muniversal-botan-patch.diff added

comment:3 Changed 11 years ago by MarcusCalhoun-Lopez (Marcus Calhoun-Lopez)

Cc: mcalhoun@… added

Cc Me!

comment:4 Changed 11 years ago by macports@…

Your patch looks good. Disabling inline assembly is not necessary after all. I had stumbled over some suspicious-looking compiler warnings related to inline assembly ("variable 'r' is uninitialized when used here"). However, the resulting machine code is indeed correct, so the warnings can be safely ignored.

I've updated my patch to include your changes.

comment:5 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)

Cc: mww@… removed
Owner: changed from macports-tickets@… to mww@…
Summary: Patch: add Python dependency and universal variant to botanbotan: add Python dependency and universal variant
Type: updateenhancement

comment:6 Changed 11 years ago by ryandesign (Ryan Carsten Schmidt)

Instead of repeated if statements, a switch statement would be shorter. Even shorter would be just referencing the merger_configure_args array that you're defining anyway. See the openssl port for an example of how to do this.

comment:7 Changed 11 years ago by macports@…

Thanks for the tips! I updated the patch accordingly.

comment:8 Changed 11 years ago by macports@…

*bump*

Changed 10 years ago by macports@…

Updated patch v3

comment:9 Changed 10 years ago by macports@…

New patch against current Portfile for version 1.10.6 attached.

comment:10 Changed 10 years ago by neverpanic (Clemens Lang)

Resolution: fixed
Status: newclosed

Oh wow, that took us a while. Anyway, in r125904 and thanks for the patch.

Note: See TracTickets for help on using tickets.