i have following error when try to compile geany, using gcc 4.8 cos ist upstream provided.. is any workaround to prioperty compile of can i disable that part?
``` [ 181s] Making all in scintilla [ 181s] make[3]: Entering directory `/usr/src/packages/BUILD/scintilla' [ 181s] Making all in include [ 181s] make[4]: Entering directory `/usr/src/packages/BUILD/scintilla/include' [ 181s] make[4]: Nothing to be done for `all'. [ 181s] make[4]: Leaving directory `/usr/src/packages/BUILD/scintilla/include' [ 181s] make[4]: Entering directory `/usr/src/packages/BUILD/scintilla' [ 182s] CXX gtk/ScintillaGTKAccessible.lo [ 182s] CXX gtk/ScintillaGTK.lo [ 182s] CXX gtk/PlatGTK.lo [ 182s] CC gtk/scintilla-marshal.lo [ 182s] CXX lexlib/Accessor.lo [ 183s] CXX lexlib/CharacterCategory.lo [ 184s] In file included from gtk/ScintillaGTKAccessible.cxx:98:0: [ 184s] ./src/UniqueString.h: In function 'UniqueString UniqueStringCopy(const char*)': [ 184s] ./src/UniqueString.h:27:26: error: use of deleted function 'std::unique_ptr<_Tp [], _Dp>::unique_ptr(_Up*, typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value>::type*) [with _Up = char; _Tp = const char; _Dp = std::default_delete<const char []>; typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value>::type = void]' [ 184s] In file included from /usr/include/c++/4.8/memory:86:0, [ 184s] from gtk/ScintillaGTKAccessible.cxx:64: [ 184s] /usr/include/c++/4.8/bits/unique_ptr.h:433:2: error: declared here [ 184s] CXX lexlib/CharacterSet.lo [ 185s] CXX lexlib/LexerBase.lo [ 185s] In file included from gtk/ScintillaGTK.cxx:49:0: [ 185s] ./src/UniqueString.h: In function 'UniqueString UniqueStringCopy(const char*)': [ 185s] ./src/UniqueString.h:27:26: error: use of deleted function 'std::unique_ptr<_Tp [], _Dp>::unique_ptr(_Up*, typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value>::type*) [with _Up = char; _Tp = const char; _Dp = std::default_delete<const char []>; typename std::enable_if<std::is_convertible<_Up*, _Tp*>::value>::type = void]' [ 185s] In file included from /usr/include/c++/4.8/memory:86:0, [ 185s] from gtk/ScintillaGTK.cxx:21: [ 185s] /usr/include/c++/4.8/bits/unique_ptr.h:433:2: error: declared here [ 185s] CXX lexlib/LexerModule.lo [ 186s] CXX lexlib/LexerNoExceptions.lo [ 186s] CXX lexlib/LexerSimple.lo [ 186s] make[4]: *** [gtk/ScintillaGTKAccessible.lo] Error 1 [ 186s] make[4]: *** Waiting for unfinished jobs.... [ 186s] make[4]: *** [gtk/ScintillaGTK.lo] Error 1 [ 187s] make[4]: Leaving directory `/usr/src/packages/BUILD/scintilla' [ 187s] make[3]: *** [all-recursive] Error 1 [ 187s] make[3]: Leaving directory `/usr/src/packages/BUILD/scintilla' [ 187s] make[2]: *** [all-recursive] Error 1 [ 187s] make[2]: Leaving directory `/usr/src/packages/BUILD' [ 187s] make[1]: *** [all] Error 2 ```
IIRC GCC 4.8 is too old, at least GCC 5.4 is needed, and probably GCC 7? for next version. A distro with 4.8 as the default compiler will usually have at least up to 5.4 available in the repos.
[Edit: assuming you are compiling Geany 1.37 a fully working C++11 compiler is needed, and as shown GCC 4.8 isn't that, 1.38 will probably need a c++17 compiler which I think is at least GCC 7]
umm ok so @elextr geany 1.30+ will need moderns compilers .. pufff please is there any workaround.. the only code part that need that is scintilla directory
IIRC GCC 4.8 is too old
i'm tyred of that shit! "too old" is the compiler provided i'm asking about any trick or workaround puff
Yes the compiler requirement is driven by Scintilla, but thats a separate project and can make its own decisions, and Geany is only one of the users of that software. Whilst a branch compatible with C++11 has been maintained until recently, because the requirement for C++17 the day the standard was released was deemed too fast, that is no longer the case, so to update Scintilla requires moving to the current version that requires C++17 and we hope to do that in 1.38 which will move the requirement.
The only possible workaround would be for somebody to take over that C++11 branch in the Scintilla project and maintain it for as long as they can, but it won't be the Geany project.
But as I said in my edit, even that branch, which we are using in 1.37, needs a _working_ C++11 compiler, GCC 4.8 is not a complete C++11 compiler, that didn't come until something like GCC 5.4 IIRC, so its not unlikely that it will have problems with some C++11. So for "too old" you can read "not standards compliant yet" if you like.
That branch intended to be compatible with compilers back to GCC 4.8, but maybe something newer leaked in or a change triggered a bug since its difficult for the (no longer) maintainer of the branch to check the backported changes from the C++17 Scintilla for compliance against a not yet standard compiler and the associated not yet standard library.
And a rant of my own if I may, I am tired of people demanding that others invest the effort to support their particular configuration with no contribution of their own. Even to find the cause and possible workarounds takes effort that somebody has to provide. As I said above, even distros that use 4.8 as their standard compiler provide newer ones in their distros, and they can be installed at the same time as 4.8. Because you are compiling the whole application yourself with one compiler, and not using any other C++ libraries, issues with ABI incompatibilities with 4.8 won't worry you. End rant.
i'm asking about any trick or workaround puff
* Build a new enough GCC for yourself * Adjust Scintilla's sources not to require features not in GCC 4.8 * If it's that simple, figure out a set of GCC 4.8 options that make it work (I'm afraid there won't be any) * Convince Scintilla's authors not to depend on C++ features not supported by your favorite version of the compiler. * Use an older version of Geany and/or Scintilla (it *might* be possible to downgrade Scintilla alone, YMMV)
I'm sorry you're frustrated, but we depend on Scintilla, and Scintilla depends on a set of C++11 features (and will even be C++17 "soon" as @elextr mentioned). We don't have enough manpower or interest in maintaining support for compilers Scintilla stopped supporting, but if you offer that yourself we'll surely consider.
Build a new enough GCC for yourself
Its probably not even necessary to do that, for example Ubuntu 16.04 (which has 4.8 as the default compiler) has 4.9 and 5.4 in the repos ready to install.
it seems is related to this commit: 170ebf610f33ac414799f1a841ae01c1e058d567 in fact the error is produced in that line and inherits
i'm asking about any trick or workaround puff
- Build a new enough GCC for yourself
- Adjust Scintilla's sources not to require features not in GCC 4.8
- If it's that simple, figure out a set of GCC 4.8 options that make it work (I'm afraid there won't be any)
- Convince Scintilla's authors not to depend on C++ features not supported by your favorite version of the compiler.
- Use an older version of Geany and/or Scintilla (it _might_ be possible to downgrade Scintilla alone, YMMV)
I'm sorry you're frustrated, but we depend on Scintilla, and Scintilla depends on a set of C++11 features (and will even be C++17 "soon" as @elextr mentioned). We don't have enough manpower or interest in maintaining support for compilers Scintilla stopped supporting, but if you offer that yourself we'll surely consider.
ok i'll try all of that options.. thanks for your response taking in cosideration my line "im tyred of that shit "upgrade bla bla" that's the right one! .. it seems related to this commit 170ebf610f33ac414799f1a841ae01c1e058d567 so i'll try to investigate a little but seems i'll need more help
And a rant of my own if I may, I am tired of people demanding that others invest the effort to support their particular configuration with no contribution of their own. Even to find the cause and possible workarounds takes effort that somebody has to provide. As I said above, even distros that use 4.8 as their standard compiler provide newer ones in their distros, and they can be installed at the same time as 4.8. Because you are compiling the whole application yourself with one compiler, and not using any other C++ libraries, issues with ABI incompatibilities with 4.8 won't worry you. End rant.
interesting paragraph .. first of all i contributed.. very little directly and a lost indirectly.. and this part :
compiling the whole application yourself with one compiler, and not using any other C++ libraries, issues with ABI incompatibilities wi..
**newer toys are just toys until becomes old and madure! a fact! in industry! and bussiness!** learn a lot first
it seems related to this commit [170ebf6](https://github.com/geany/geany/commit/170ebf610f33ac414799f1a841ae01c1e058d5...) so i'll try to investigate a little but seems i'll need more help
I hardly think this commits has anything to do with your problems, and I don't see any reference to that in your OP.
BTW you didn't say what version you are trying to build (neither on what environment). It doesn't look like you're trying the current release (1.37) though.
[Edit: assuming you are compiling Geany 1.37 a fully working C++11 compiler is needed, and as shown GCC 4.8 isn't that
There's one thing that puzzles me a bit: [GCC claims 4.8 is a full-featured C++11 compiler](https://gcc.gnu.org/projects/cxx-status.html#cxx11). Of course there might be bugs, but well. But if we accidentally started to depend on C++14, we probably should write this down :)
But if we accidentally started to depend on C++14, we probably should write this down
Not knowingly, Longterm3 branch claims "avoiding C++14" but Mitchell could have made a mistake, but since he has retired the branch its not going to be fixed if something did sneak in.
@b4n to explain, the 4.8 _compiler_ may be "full featured" but the standard library wasn't standards compliant for `std::string` until "In the GCC 5.1 release libstdc++ introduced a new library ABI that includes new implementations of std::string and std::list." so its egregious of GCC to claim its compliant when even something as common as `std::string` is not compliant in the associated library, so who knows what else isn't. I'll be ranting again in a minute because it has always irked me that GCC ignores the state of the standard library shipped with it, even though its required to make it work. :grin:
@mckaygerhard "i'm tyred of that shit! "too old" is the compiler provided" is the reason for my gentle rant, its not so nice when people rant at you is it? So please don't swear, make demands, or demeaning statements in __bold__. As Geany is a volunteer project people contribute what they want to contribute, and things like that just make them want to not help you.
The errors posted in the OP (assuming Scintilla 3.7.5 or earlier, the line is blank in later versions) do indeed look like a known bug in early C++11 compilers that didn't detect the return value was an rvalue and required `std::move` on them. Of course then once that was fixed, later compilers complained that the explicit `std::move` prevented them from eliding the copy, so the `std::move` had to be removed.
Basically its simply not possible to support both the erroneous compiler and correct ones. I remember discussing with Neil the issue of needing a compiler upgrade across the GCC 4.8-5 boundary and its ABI break would have on C++ projects that used any pre-compiled C++ as well as Scintilla, but I can't find it again now (paging @codebrainz search services). But as I said above thats not a problem for Geany which compiles all the C++ it uses and only uses C libraries that are precompiled, and the C abi hasn't been broken since forever.
ummno w correctly copy cat adn understand.. puff so i cant backport geany 1.33 to olders versions of my production environment devbelopers.. puff i already noted you guys were using the LongTerm3 brand for a while .. so i cant make anything .. so i will try to backport the 1.26 version or less, i already know that 1.24 already compiles for gcc 4.7
Closed #2731.
paging @codebrainz search services
https://groups.google.com/g/scintilla-interest/c/ma_3cmKAEVs/m/n61l9uT4BQAJ
Maybe you could work out a patch for your use case using @elextr's suggestions about `std::move()`, if you're C++ proficient enough to understand the implications (I don't, it's not C :grin: )
Maybe you could work out a patch for your use case using @elextr's suggestions about `std::move()`, if you're C++ proficient enough to understand the implications (I don't, it's not C )
neither me :< snif... i will try with a frined.. thanks for all guys
github-comments@lists.geany.org