Removed a macro for MSVC, simplified an #if ... else
Simplified #if defined(COMPILER_MINGW) && defined(PTW32_VERSION) ... #else... . This was responsible for errors when compiling libs/ardour/midi_ui.cc.
Removed DECLARE_DEFAULT_COMPARISONS(ptw32_handle_t) which was only for MSVC. Also adjusted ardourext/misc.h to reflect these changes.
Why is Stephen being allowed to edit my ".input" files?? The whole point of asking him to copy them was so he could limit any edits (initially) to the copies.
Well I figured my edit in this pull request would make that section of the .input files redundant, so I edited it. I'll check if there's any other changes I made to abstract_ui.inc.cc that might've been left out.
Upon checking: No other edit to abstract_ui.inc.cc.
Groan... so if I decide to remove your code will that be okay too? In abstract_ui.inc.cc there was even a comment explaining why the comparisons were needed - so apparently, you decided to remove that too :-(
Why is Stephen being allowed to edit my ".input" files?? The whole point of asking him to copy them was so he could limit any edits (initially) to the copies.
This is a pull request, not commits to ardour/master ....
I don't get it... how does a pull request stop the code from being compilable??
My point is that EZ4Stephen's changes documented here have not yet been applied to the ardour/master branch (and may not be). They are proposing changes ... they have not yet been accepted.
Okay Paul but either way - Stephen needs to be aware that he mustn't remove sections of code simply because he doesn't see any need for them. Even if that code wasn't needed in Ardour (which is unlikely...) it might easily be getting used in Mixbus.
This is why I flagged this up for discussion, before merging the change. I suspected that they may break existing MSVC builds, but was not sure about it.
You suggested to copy/edit the files in https://discourse.ardour.org/t/building-with-msvc-powershell-errors/112468/87 but those edits won't persist.. so we need to find a solution.
I suggest to simply add a #ifdef WAF_BUILD or #if defined COMPILER_MSVC && defined WAF_BUILD to abstract-ui, and pthread_utils.cc
and/or perhaps simply copy msvc_extra_headers/ardourext/ outright to a new folder for waf builds, should that be needed.
You suggested to copy/edit the files in https://discourse.ardour.org/t/building-with-msvc-powershell-errors/112468/87 but those edits won't persist.. so we need to find a solution.
Yes, but some solutions can wait until later whereas others need to be found now (see below)
I suggest to simply add a
#ifdef WAF_BUILDor#if defined COMPILER_MSVC && defined WAF_BUILDto abstract-ui, and pthread_utils.cc
Well that's certainly preferable to having Stephen arbitrarily remove code. For WAF_BUILD however:-
It seems to be used currently for applying config settings. But for what you're suggesting (IIUC) there's an obvious danger that we'd end up with whole sections of code which sometimes get built with MSVC and sometimes they don't.
I'd prefer to start by us ensuring that Stephen has implemented the changes already suggested to him - e.g. in post 19 from that same thread. In fact at the time of writing I'm not even sure if his builds are #defining _WIN64 - let alone the others.
I'd prefer to start by us ensuring that Stephen has implemented the changes already suggested to him - e.g. in post 19 from that same thread.
If it helps, I could maybe split those defines into which ones are needed for the whole build and which ones need to be adapted per project - e.g. when building libardour, BUILDING_PBD would need to become BUILDING_LIBARDOUR
Sorry for the late response, I was away. While I don't quite understand how a pull request caused errors for John's build, I acknowledge it causing errors. I'll abandon this request and create a new one for just abstract_ui.h (different than what's in this pull request). I feel further discussion can continue here, so I haven't closed this myself.
The suggestion of using #if defined COMPILER_MSVC && defined WAF_BUILD for pthread_utils and abstract_ui is noted. Given I'm kinda stuck at libs/ardour's unresolved errors for my build, I can try some changes for pthread_utils soon.
Splitting the defines would be appreciated, John. Sorry about the errors once again, I wrongly assumed the edits to abstract_ui.h would make that paragraph redundant.
Splitting the defines would be appreciated, John.
Okay Stephen - on your Ardour thread (to get you started) I've just posted the #defines needed for building libpbd:-