IJHack / QtPass

QtPass is a multi-platform GUI for pass, the standard unix password manager.

Home Page:https://qtpass.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Restore/fix support for Qt4

barracuda156 opened this issue · comments

While source code implies a possibility of building with Qt4

greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
– it is broken, unfortunately. Apparently broken for quite a while: I have tried building QtPass back to v. 1.2.3, and it kept failing with similar errors.

Could support for Qt4 be restored? (If it was removed in an organized way, I can revert needed commits and make a PR. Presently I have no idea whether it was done in some coherent way or in random commits.)

So there were two pointes which has broken QtPass:

  1. An arbitrary SDK has been forced in 7e735f3 which obviously could not end up nicely :)
  2. Nevertheless, with that line removed, everything up to 1.1.6 builds fine. However, 1.2.0 is badly broken. There are tons of commits in between, not yet sure what exactly has broken the build and whether it is a single or multiple issues.

I have found why it was broken. There was a bunch of “improvements” leading to:

:info:build executor.h:78:46: error: 'Q_NULLPTR' was not declared in this scope
:info:build    78 |                       QString *process_out = Q_NULLPTR,
:info:build       |                                              ^~~~~~~~~
:info:build executor.h:79:46: error: 'Q_NULLPTR' was not declared in this scope
:info:build    79 |                       QString *process_err = Q_NULLPTR);
:info:build       |                                              ^~~~~~~~~
:info:build executor.h:82:68: error: 'Q_NULLPTR' was not declared in this scope
:info:build    82 |                       QString *process_out, QString *process_err = Q_NULLPTR);
:info:build       |                                                                    ^~~~~~~~~
. . .
:info:build imitatepass.h:39:43: error: expected ';' at end of member declaration
:info:build    39 |                         const QString &err) Q_DECL_OVERRIDE;
:info:build       |                                           ^
:info:build       |                                            ;
:info:build imitatepass.h:39:45: error: 'Q_DECL_OVERRIDE' does not name a type; did you mean 'Q_OVERRIDE'?
:info:build    39 |                         const QString &err) Q_DECL_OVERRIDE;
:info:build       |                                             ^~~~~~~~~~~~~~~
:info:build       |                                             Q_OVERRIDE
:info:build imitatepass.h:44:53: error: expected ';' at end of member declaration
:info:build    44 |                               bool readStderr = true) Q_DECL_OVERRIDE;
:info:build       |                                                     ^
:info:build       |                                                      ;
:info:build imitatepass.h:44:55: error: 'Q_DECL_OVERRIDE' does not name a type; did you mean 'Q_OVERRIDE'?
:info:build    44 |                               bool readStderr = true) Q_DECL_OVERRIDE;
:info:build       |                                                       ^~~~~~~~~~~~~~~
:info:build       |                                                       Q_OVERRIDE
:info:build imitatepass.h:49:24: error: expected ';' at end of member declaration
:info:build    49 |   virtual void GitInit() Q_DECL_OVERRIDE;
:info:build       |                        ^
:info:build       |                         ;

This is Qt5-only syntax: https://forum.qt.io/topic/66593/error-q_decl_override-does-not-name-a-type
CsoundQt/CsoundQt#228

Breaking commits:
5b8e9cd
7cd15e7
12c08ea

Will see if fixing these will fix the build.

UPD. This does not work too: e0964b9