Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » Gearing up for 2022.1 release...
Re: Gearing up for 2022.1 release... [message #58253 is a reply to message #58252] Tue, 05 April 2022 15:29 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
Tom1 wrote on Tue, 05 April 2022 09:00

The latest nightly (upp-win-16223.7z) shows version 11.0.0. for clang:

I personally checked against git ...


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58255 is a reply to message #58249] Tue, 05 April 2022 21:00 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
Novo wrote on Tue, 05 April 2022 00:46

I do see a weird problem with Md5Stream. I'll check it tomorrow.

It turned out to be a weird problem with FindAllPaths + wine + unix-style path.
For examle:
FindAllPaths("/home/ssg/data/download", "*.pdf")

will return
v = Z:\home\ssg\dvlp\cpp\code\upp\out\MyApps\MINGWcpp17.Debug.Debug_Full.Gui.Shared.Win32\home\ssg\data\download\mysqluc2007-wikipedia-workbook.pdf
v = Z:\home\ssg\dvlp\cpp\code\upp\out\MyApps\MINGWcpp17.Debug.Debug_Full.Gui.Shared.Win32\home\ssg\data\download\recsplit.pdf
v = Z:\home\ssg\dvlp\cpp\code\upp\out\MyApps\MINGWcpp17.Debug.Debug_Full.Gui.Shared.Win32\home\ssg\data\download\StatisticsWithJuliaDRAFT.pdf
v = Z:\home\ssg\dvlp\cpp\code\upp\out\MyApps\MINGWcpp17.Debug.Debug_Full.Gui.Shared.Win32\home\ssg\data\download\UHHA Info Update 5-8-20.pdf
v = Z:\home\ssg\dvlp\cpp\code\upp\out\MyApps\MINGWcpp17.Debug.Debug_Full.Gui.Shared.Win32\home\ssg\data\download\web-prolog.pdf
v = Z:\home\ssg\dvlp\cpp\code\upp\out\MyApps\MINGWcpp17.Debug.Debug_Full.Gui.Shared.Win32\home\ssg\data\download\whole-book.pdf

This can be a problem with wine, Upp or both ...

Another thing. In case of Wine + Upp log-file is created in an app folder. SetConfigGroup is ignored. I guess this is done "by design".


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58256 is a reply to message #58255] Wed, 06 April 2022 09:07 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
It turned out that Windows has a command line package manager called "winget" now. (This, probably, was already discussed on this forum)
IMHO, it would be cool to have an Upp package for it.
Installing Upp via "winget install Upp" seems to be the easiest way to get it.
And "winget search upp" seems to be the easiest way to find it.


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58257 is a reply to message #58256] Wed, 06 April 2022 11:59 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Novo wrote on Wed, 06 April 2022 09:07
It turned out that Windows has a command line package manager called "winget" now. (This, probably, was already discussed on this forum)
IMHO, it would be cool to have an Upp package for it.
Installing Upp via "winget install Upp" seems to be the easiest way to get it.
And "winget search upp" seems to be the easiest way to find it.


Go for it Smile
Re: Gearing up for 2022.1 release... [message #58258 is a reply to message #58251] Wed, 06 April 2022 12:05 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Klugier wrote on Tue, 05 April 2022 12:21
mirek wrote on Sun, 03 April 2022 19:36
Klugier wrote on Sun, 03 April 2022 15:43
Hello Mirek,

I also proposed bumping C++ standard from c++14 to c++17. However, this could be done in the next release. There are a lot of risks here in context of compilation on various platforms.

Even if we do not have any features that particularly targets c++17 we should compile with that standard and our users should have access to it by default. Also, maybe this is a bug, but for MSVC we do not force any standard. It is always latest. I think it should change and we should target exactly the same standard as for GCC and CLANG.

Klugier


Yeeah, I was thinking about it a lot, problem is we have so far universal package for Posixes and we are not 100% sure c++17 compliant compiler is there. I think we would need to add detection code before adding -std=c++17 to options, which is sort of complicated and quirky.


Hello Mirek,

What about chaning approch? If it doesn't compile you could always back to older stable release of Upp. The old systems shouldn't hold us back and keep with old standard. We could make 2022.1 last official release with c++14 and the next one will be c++17.

The C++14 was introduced in 2017 in our code base. 3 years after official standard announcement. Right now we are 5 years after c++17. There is no consistency here.

Klugier



Uhm, now we are mixing 2 things I guess:

(1) C++ that is required by U++
(2) default C++ setting of build methods

So far I was speaking about (2). As for (1) I do not as of now see anything in C++17 that would make U++ codebase significantly better (cleaner, shorter, faster), so IMO it is not worth it to break U++ for old systems yet.

I could go with (2), but that would require detection system for posix install. IDK, maybe running "c++ -std=c++17" and detecting the error code would do the job?

Mirek
Re: Gearing up for 2022.1 release... [message #58260 is a reply to message #58257] Wed, 06 April 2022 19:04 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
mirek wrote on Wed, 06 April 2022 05:59
Novo wrote on Wed, 06 April 2022 09:07
It turned out that Windows has a command line package manager called "winget" now. (This, probably, was already discussed on this forum)
IMHO, it would be cool to have an Upp package for it.
Installing Upp via "winget install Upp" seems to be the easiest way to get it.
And "winget search upp" seems to be the easiest way to find it.


Go for it Smile

I'm not a Windows person. )
First of all I need to figure out how to legally get/build a QEMU Windows 11 VM which I need for testing.
Your suggestions are welcome!


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58261 is a reply to message #58260] Wed, 06 April 2022 19:21 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
Another issue.
Linking options from the "Output mode" dialog completely overwrite these options from a builder.
This is fine when you develop for only one platform. ("All static" for Windows and "Use shared libs" for POSIX)
But when you need to cross-compile this becomes a problem.
Suddenly your Windows apps start requiring dependencies ...
It took me quite a lot of time to realize that.

P.S. Interesting, what happens in case of umk ...


Regards,
Novo

[Updated on: Wed, 06 April 2022 19:49]

Report message to a moderator

Re: Gearing up for 2022.1 release... [message #58262 is a reply to message #58258] Wed, 06 April 2022 19:34 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
mirek wrote on Wed, 06 April 2022 06:05

(1) C++ that is required by U++
(2) default C++ setting of build methods

IMHO, it makes sense to ship Upp with different C++-versioned builders.
CLANG14, CLANG17, e.t.c instead of just a CLANG ...
And Upp should be tested against all versions of C++ because old code often doesn't compile with new versions of C++.
I personally use C++17 because my own code doesn't compile with older versions of C++ Cool


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58263 is a reply to message #58262] Thu, 07 April 2022 10:42 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Novo wrote on Wed, 06 April 2022 19:34
mirek wrote on Wed, 06 April 2022 06:05

(1) C++ that is required by U++
(2) default C++ setting of build methods

IMHO, it makes sense to ship Upp with different C++-versioned builders.
CLANG14, CLANG17, e.t.c instead of just a CLANG ...
And Upp should be tested against all versions of C++ because old code often doesn't compile with new versions of C++.
I personally use C++17 because my own code doesn't compile with older versions of C++ Cool


Yes, that is another possibility. Anyway, I postpone this until next release.
Re: Gearing up for 2022.1 release... [message #58265 is a reply to message #58262] Thu, 07 April 2022 12:16 Go to previous messageGo to next message
Tom1
Messages: 1212
Registered: March 2007
Senior Contributor
Hi,

Bundled clang in windows now seems up to version 14.0.0. Smile

However, when linking my project with CLANG I get the following error:
Linking...
ld.lld: error: duplicate symbol: std::__throw_bad_alloc()
>>> defined at C:/upp-git/out/program/Core/CLANGx64.Blitz.Gui.Protect/heap.o
>>> defined at libc++.a(new.cpp.obj)
clang-14: error: linker command failed with exit code 1 (use -v to see invocation)

There were errors. (1:31.25)

Please note that this is not specific to CLANG-14 but also happened with previous CLANG version bundled.

Any idea where this comes from and suggestions how to proceed?

Best regards,

Tom

[Updated on: Thu, 07 April 2022 12:17]

Report message to a moderator

Re: Gearing up for 2022.1 release... [message #58266 is a reply to message #58263] Thu, 07 April 2022 12:55 Go to previous messageGo to next message
Klugier is currently offline  Klugier
Messages: 1076
Registered: September 2012
Location: Poland, Kraków
Senior Contributor
Hello Mirek,

I still think that we should bump c++ version everywhere. There are some features that could be use within Upp code base such as structural binding, nested namespaces or declaring variable in if, switch statement. There are also a lot of features in the standard library like std::optional. Anyway, we should go forward. C++20 is a head of us with much more important feature such as modules and concepts. If we do not want to switch to c++17 right now, so when we will switch to c++20. In 2030?

If the POSIX bundle will do not compile on the oldest system you could always back to previous stable release which supports older standards and you could always install newer compiler version to overcome the problem. In reality to support c++17 we need compiler from 2016/2017.

I am not sure introducing CLANG17 will give us something instead of additional configuration file. You could switch standard by modifying CLANG inside TheIDE after installation and replacing it by -std=c++17. Very easy, however it would be good to have it by default.

Klugier


U++ - one framework to rule them all.
Re: Gearing up for 2022.1 release... [message #58267 is a reply to message #58265] Thu, 07 April 2022 13:21 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Tom1 wrote on Thu, 07 April 2022 12:16
Hi,

Bundled clang in windows now seems up to version 14.0.0. Smile

However, when linking my project with CLANG I get the following error:
Linking...
ld.lld: error: duplicate symbol: std::__throw_bad_alloc()
>>> defined at C:/upp-git/out/program/Core/CLANGx64.Blitz.Gui.Protect/heap.o
>>> defined at libc++.a(new.cpp.obj)
clang-14: error: linker command failed with exit code 1 (use -v to see invocation)

There were errors. (1:31.25)

Please note that this is not specific to CLANG-14 but also happened with previous CLANG version bundled.

Any idea where this comes from and suggestions how to proceed?

Best regards,

Tom


It rings some bells:

https://github.com/mstorsjo/llvm-mingw/issues/91

Core/heap.cpp:302

Mirek
Re: Gearing up for 2022.1 release... [message #58268 is a reply to message #58267] Thu, 07 April 2022 13:40 Go to previous messageGo to next message
Tom1
Messages: 1212
Registered: March 2007
Senior Contributor
Hi Mirek,

I thought, now that CLANG is at version 14, the issue would have been solved.
 mstorsjo commented on Apr 23, 2021

This should have been fixed by the previous release (based on LLVM 11.0.0).

Best regards,

Tom
Re: Gearing up for 2022.1 release... [message #58269 is a reply to message #58268] Thu, 07 April 2022 15:07 Go to previous messageGo to next message
Tom1
Messages: 1212
Registered: March 2007
Senior Contributor
Hi Mirek,

I commented out the following line in heap.cpp:
void __attribute__((__noreturn__)) std::__throw_bad_alloc (void) { throw bad_alloc(); }

As a result the linker stopped complaining about it. Is this line required at all anymore?

(There are some external static libs I need that still prevent my app from running, but that's another story.)

Best regards,

Tom
Re: Gearing up for 2022.1 release... [message #58270 is a reply to message #58266] Thu, 07 April 2022 22:57 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
Klugier wrote on Thu, 07 April 2022 06:55

I still think that we should bump c++ version everywhere.

I have a different proposal. Smile Upp doesn't really use any of C++14 language features. C++14 added improved constexpr support. Upp doesn't use it. It uses just a couple of C++14-specific stl files (maybe, just one). So, by dropping of this dependency and implementing this functionality in Upp itself it will be possible to lower C++ version requirement to C++11. Smile


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58271 is a reply to message #58262] Thu, 07 April 2022 23:21 Go to previous messageGo to next message
Novo is currently offline  Novo
Messages: 1358
Registered: December 2006
Ultimate Contributor
Novo wrote on Wed, 06 April 2022 13:34

And Upp should be tested against all versions of C++ because old code often doesn't compile with new versions of C++.

TheIDE cannot be compiled with C++20.
Clang + -std=c++20
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/CtrlCore/CtrlPos.cpp:152:11: error: use of overloaded operator '!=' is ambiguous (with operand types 'Upp::Rect' (aka 'Rec
    t_<int>') and 'Upp::Rect16' (aka 'Rect_<short>'))
                if(view != f.view) {
                   ~~~~ ^  ~~~~~~
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/Core/Gtypes.h:337:9: note: candidate function
        bool   operator!=(const Rect_& b) const                 { return !operator==(b); }
               ^
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/Core/Gtypes.h:336:9: note: candidate function
        bool   operator==(const Rect_& b) const;
               ^
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/Core/Gtypes.h:336:9: note: candidate function (with reversed parameter order)

IMHO, this should be fixed.


Regards,
Novo
Re: Gearing up for 2022.1 release... [message #58273 is a reply to message #58270] Fri, 08 April 2022 09:43 Go to previous messageGo to next message
Tom1
Messages: 1212
Registered: March 2007
Senior Contributor
Hi Novo,

I like your idea of flexibility here. It is far easier to maintain projects across platforms if the latest uppsrc works nicely (i.e. is compatible) with all the standards from c++11 to c++20 -- or whatever the latest is. Anyway, there are always dependencies that cause all kinds of trouble with their requirements, so keeping uppsrc widely compatible is an excellent choice.

Best regards,

Tom
Re: Gearing up for 2022.1 release... [message #58274 is a reply to message #58271] Fri, 08 April 2022 11:09 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Novo wrote on Thu, 07 April 2022 23:21
Novo wrote on Wed, 06 April 2022 13:34

And Upp should be tested against all versions of C++ because old code often doesn't compile with new versions of C++.

TheIDE cannot be compiled with C++20.
Clang + -std=c++20
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/CtrlCore/CtrlPos.cpp:152:11: error: use of overloaded operator '!=' is ambiguous (with operand types 'Upp::Rect' (aka 'Rec
    t_<int>') and 'Upp::Rect16' (aka 'Rect_<short>'))
                if(view != f.view) {
                   ~~~~ ^  ~~~~~~
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/Core/Gtypes.h:337:9: note: candidate function
        bool   operator!=(const Rect_& b) const                 { return !operator==(b); }
               ^
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/Core/Gtypes.h:336:9: note: candidate function
        bool   operator==(const Rect_& b) const;
               ^
/home/ssg/dvlp/cpp/code/upp/git/uppsrc/Core/Gtypes.h:336:9: note: candidate function (with reversed parameter order)

IMHO, this should be fixed.


Unfortunately, that just seems to be the tip of the iceberg.

Frankly, are they paid for screwing our code every 3 years or what? Smile

(Fixing things now..)

Mirek
Re: Gearing up for 2022.1 release... [message #58275 is a reply to message #58270] Fri, 08 April 2022 11:19 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
Novo wrote on Thu, 07 April 2022 22:57
Klugier wrote on Thu, 07 April 2022 06:55

I still think that we should bump c++ version everywhere.

I have a different proposal. Smile Upp doesn't really use any of C++14 language features.


Actually, we use C++14 lambda features that cannot be worked around. But I would like to stay there (at C++ 14).

Mirek
Re: Gearing up for 2022.1 release... [message #58276 is a reply to message #58145] Fri, 08 April 2022 12:42 Go to previous messageGo to previous message
mr_ped is currently offline  mr_ped
Messages: 825
Registered: November 2005
Location: Czech Republic - Praha
Experienced Contributor
IMHO:
- upp packages "should" compile also in C++20 mode, so user apps can use the C++20 (would be really nice to have this fixed before 2022.1 release)
- changing minimal requirement from C++14 to C++17 without using it is useless, just adding artificial hurdle (some users may be forced to C++14 in their projects)
- refactoring the code to use C++17 just before 2022.1 release just for the sake of using C++17 is also weird use of dev-time

My understanding is that U++ is almost ready for release, and unless there is some practical value in using C++17 for remaining tasks, it is IMHO much better to release it as C++14 compatible (but ideally with C++17 and C++20 compatibility too), that enables most options for users.

And things like bumping minimal version should be rather done at beginning of the release (ideally when some new features also make sense and will be used actively), not in last minute before release.
Previous Topic: 2022.1rc1
Next Topic: 2022.1rc2
Goto Forum:
  


Current Time: Sat Apr 27 12:16:01 CEST 2024

Total time taken to generate the page: 0.06496 seconds