Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Botan 3 build #9388

Merged
merged 4 commits into from
May 7, 2023
Merged

Conversation

pobrn
Copy link
Contributor

@pobrn pobrn commented May 4, 2023

Botan commit 819cf8fe6278a19b8266f449228f02fc28a4f784 changed
Botan::Cipher_Dir to be a scoped enumeration, so the users
must be adapted.

This change causes no issues with Botan 2 because normal
enumeration values can also be referred to the same way
scoped enumeration values are accessed.

@droidmonkey
Copy link
Member

I would like to have cmake automatically enable the botan 3 compile flag if that version is found. Can you incorporate?

@droidmonkey droidmonkey added this to the v2.7.5 milestone May 4, 2023
@pobrn
Copy link
Contributor Author

pobrn commented May 4, 2023

I can certainly try but I don't really know CMake, so I am definitely not the best person to do it.

Botan commit 819cf8fe6278a19b8266f449228f02fc28a4f784 changed
Botan::Cipher_Dir to be a scoped enumeration, so the users
must be adapted.

This change causes no issues with Botan 2 because normal
enumeration values can also be referred to the same way
scoped enumeration values are accessed.
@droidmonkey
Copy link
Member

droidmonkey commented May 4, 2023

Ok, I can add it then no biggie

@droidmonkey
Copy link
Member

I added a way to auto-detect Botan3 and set everything up correctly if it is found. Fallback is to Botan2 as before. Can you test this on your end to make sure it works correctly? None of our CI has Botan3 installed on it.

@droidmonkey droidmonkey changed the title SymmetricCipher: Fix Botan 3 build Fix Botan 3 build May 6, 2023
@pobrn
Copy link
Contributor Author

pobrn commented May 6, 2023

Seems to work with Botan 3.

@pobrn
Copy link
Contributor Author

pobrn commented May 6, 2023

None of our CI has Botan3 installed on it.

Looks like the MacOS one (now) has Botan 3. The build failure there should be fixed by #9389.

@pobrn
Copy link
Contributor Author

pobrn commented May 6, 2023

Found Botan3: C:/vcpkg/installed/x64-windows/lib/botan.lib (found version "2.19.1")

This is certainly odd.

`std::result_of` was deprecated in C++17 and then it was
subsequently removed in C++20. One could use `std::invoke_result_t`,
but let Qt figure out the return type instead.
@droidmonkey
Copy link
Member

Yah I'm live testing on the macOS CI box. I incorporated your C++20 fix into this PR

@droidmonkey droidmonkey self-requested a review May 6, 2023 18:25
@droidmonkey
Copy link
Member

Looks like I need to fix windows, it is finding botan and thinking it is version 3. We may need to collapse the FindBotan3 and FindBotan2 cmake files into one.

@droidmonkey droidmonkey merged commit 16b3d32 into keepassxreboot:develop May 7, 2023
@pobrn pobrn deleted the fix_botan3_build branch May 7, 2023 13:55
droidmonkey added a commit that referenced this pull request May 8, 2023
* SymmetricCipher: Fix Botan 3 build

Botan commit 819cf8fe6278a19b8266f449228f02fc28a4f784 changed
Botan::Cipher_Dir to be a scoped enumeration, so the users
must be adapted.

This change causes no issues with Botan 2 because normal
enumeration values can also be referred to the same way
scoped enumeration values are accessed.

* Auto detect Botan3

* AsyncTask: Do not use `std::result_of`

`std::result_of` was deprecated in C++17 and then it was
subsequently removed in C++20. One could use `std::invoke_result_t`,
but let Qt figure out the return type instead.

* Collapse Botan2 and Botan3 find package into one

* Update COPYING

---------

Co-authored-by: Jonathan White <support@dmapps.us>

Add missing include. (#9403)
droidmonkey added a commit that referenced this pull request May 8, 2023
Fix Botan 3 build (#9388)

* SymmetricCipher: Fix Botan 3 build

Botan commit 819cf8fe6278a19b8266f449228f02fc28a4f784 changed Botan::Cipher_Dir to be a scoped enumeration, so the users must be adapted.

This change causes no issues with Botan 2 because normal enumeration values can also be referred to the same way scoped enumeration values are accessed.

* Auto detect Botan3

* AsyncTask: Do not use `std::result_of`

`std::result_of` was deprecated in C++17 and then it was subsequently removed in C++20. One could use `std::invoke_result_t`, but let Qt figure out the return type instead.

* Collapse Botan2 and Botan3 find package into one

* Update COPYING
@TimB87 TimB87 mentioned this pull request May 12, 2023
archlinux-github pushed a commit to archlinux/svntogit-community that referenced this pull request May 17, 2023
Support has been added in 2.7.5

keepassxreboot/keepassxc@ebc0b3f
keepassxreboot/keepassxc#9322
keepassxreboot/keepassxc#9388

git-svn-id: file:///srv/repos/svn-community/svn@1462989 9fca08f4-af9d-4005-b8df-a31f2cc04f65
archlinux-github pushed a commit to archlinux/svntogit-community that referenced this pull request May 17, 2023
Support has been added in 2.7.5

keepassxreboot/keepassxc@ebc0b3f
keepassxreboot/keepassxc#9322
keepassxreboot/keepassxc#9388


git-svn-id: file:///srv/repos/svn-community/svn@1462989 9fca08f4-af9d-4005-b8df-a31f2cc04f65
Perlover added a commit to Perlover/keepassxc that referenced this pull request May 18, 2023
Release 2.7.5

- Add menu option to allow screenshots [keepassxreboot#8841]
- Add support for Botan 3 [keepassxreboot#9388]
- Increase max TOTP step to 24 hours [keepassxreboot#9149]
- Improve HTML export layout [keepassxreboot#8987]
- Turn search reset off by default [keepassxreboot#9153]
- Use QClipboard::clear() instead of setting blank text [keepassxreboot#9148]
- Hide group column header choice when not in search [keepassxreboot#9171]
- Improve look of KeePassXC logo and icons [keepassxreboot#9355]
- Add keyboard shortcuts for app and database settings [keepassxreboot#9007]
- Hide rename button from attachments preview panel [keepassxreboot#8842]
- Linux: Set SingleMainWindow in .desktop file [keepassxreboot#7430]

- Fix crash when search clears while creating new entry [keepassxreboot#9230]
- Fix crash when using Windows Hello in a Remote Desktop session [keepassxreboot#9006]
- Fix crash in Group Edit after enabling Browser Integration [keepassxreboot#8778]
- Fix canceling quick unlock when it is unavailable [keepassxreboot#9034]
- Set password input field font correctly [keepassxreboot#8732]
- Greatly improve performance when rendering entry view [keepassxreboot#9398]
- Fix various accessibility issues [keepassxreboot#9138]
- Fix arrows size when expand/collapse a group [keepassxreboot#9096]
- Select the clone instead of the original after cloning an entry [keepassxreboot#9070]
- Fix bugs with preview widget [keepassxreboot#9170]
- Fix status bar update when switching to other DB [keepassxreboot#9073]
- Fix database settings spin box bug [keepassxreboot#9101]
- Fix Ctrl+Tab shortcut to cycle databases in unlock dialog [keepassxreboot#8839]
- Fix TOTP QR code maintaining square ratio [keepassxreboot#9027]
- Fix Auto-Type configuration page on custom sequence selection [keepassxreboot#8752]
- Fix unexpected behavior of `--lock` when KeePassXC is not running [keepassxreboot#8889]
- Make open folder icon exempt from "Apply group icon to entry" [keepassxreboot#9205]
- Allow setting default file open directory with env var [keepassxreboot#9192]
- SSH Agent: Fix support for AES-256/GCM openssh keys [keepassxreboot#8968]
- Browser: Fix Native Messaging script path with BSD OS's [keepassxreboot#8835]
- MacOS: Fix text selection for Auto-Type clear field [keepassxreboot#9066]
- MacOS: Don't rely on AppleInterfaceStyle for theme switching [keepassxreboot#8615]
- Windows: Remove registry detection of desktop shortcut [keepassxreboot#9380]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants