|
From: Frank N. <bea...@we...> - 2020-02-02 18:54:57
|
Hi all,
not sure if I overlooked some recent build requirement change, but with Linux
Mint 19.2 (gcc 7.4.0) I seem to be unable to build current LinuxSampler
(svn r3734) from source (but thie issue might been in for a while already):
Sequence up this point was "make -f Makefile.svn && ./configure && make -j4".
...
make[5]: Entering directory '/home/franky/src/audio/linuxsampler/svn/build/linuxsampler/src/scriptvm'
depbase=`echo parser.lo | sed 's|[^/]*$|.deps/&|;s|\.lo$||'`;\
/bin/bash ../../libtool --tag=CXX --mode=compile g++ -std=gnu++14 -DHAVE_CONFIG_H -I. -I../.. -Wreturn-type -ffast-math -g -O2 -pthread -MT parser.lo -MD -MP -MF $depbase.Tpo -c -o parser.lo parser.cpp &&\
mv -f $depbase.Tpo $depbase.Plo
libtool: compile: g++ -std=gnu++14 -DHAVE_CONFIG_H -I. -I../.. -Wreturn-type -ffast-math -g -O2 -pthread -MT parser.lo -MD -MP -MF .deps/parser.Tpo -c parser.cpp -fPIC -DPIC -o .libs/parser.o
In file included from tree.h:27:0,
from parser_shared.h:16,
from parser.y:14:
../common/ArrayList.h:67:44: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
void remove(ssize_t iPosition) throw (Exception) {
^~~~~
In file included from tree.h:28:0,
from parser_shared.h:16,
from parser.y:14:
../common/optional.h:73:34: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
const T& get() const throw (Exception) {
^~~~~
../common/optional.h:78:22: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
T& get() throw (Exception) {
^~~~~
../common/optional.h:105:41: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
const T& operator *() const throw (Exception) { return get(); }
^~~~~
../common/optional.h:106:41: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
T& operator *() throw (Exception) { return get(); }
^~~~~
../common/optional.h:108:42: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
const T* operator ->() const throw (Exception) {
^~~~~
../common/optional.h:113:30: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
T* operator ->() throw (Exception) {
^~~~~
In file included from parser_shared.h:24:0,
from parser.y:14:
../common/global_private.h:99:40: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
inline int ToInt(const std::string& s) throw(LinuxSampler::Exception) {
^~~~~
../common/global_private.h:106:44: warning: dynamic exception specifications are deprecated in C++11 [-Wdeprecated]
inline float ToFloat(const std::string& s) throw(LinuxSampler::Exception) {
^~~~~
parser.y: In function ‘int InstrScript_parse(LinuxSampler::ParserContext*)’:
parser.y:311:25: sorry, unimplemented: non-trivial designated initializers not supported
});
^
parser.y:311:25: sorry, unimplemented: non-trivial designated initializers not supported
parser.y:311:25: sorry, unimplemented: non-trivial designated initializers not supported
parser.y:311:25: sorry, unimplemented: non-trivial designated initializers not supported
parser.y:318:26: sorry, unimplemented: non-trivial designated initializers not supported
});
^
There is a whole bunch more of these "sorry, unimplemented..." lines on the same file.
Bison version is 3.0.4.
I rebuilt&installed current libgig/liblscp packages before building this one, all fine so far.
Do I have to run some manual "generate" step first?
Thanks for any hints,
Frank
|
|
From: Christian S. <sch...@li...> - 2020-02-02 22:22:14
|
On Sonntag, 2. Februar 2020 19:54:43 CET Frank Neumann wrote: > Hi all, Hi Frank, > not sure if I overlooked some recent build requirement change, but with > Linux Mint 19.2 (gcc 7.4.0) I seem to be unable to build current > LinuxSampler (svn r3734) from source (but thie issue might been in for a > while already): The build requirement has in fact changed after last year's release: http://doc.linuxsampler.org/Release_Notes/LinuxSampler_2_1_1/ Like mentioned in those release notes, I've added a bunch of new features after that release, which would be hard to maintain without modern C++ standard support by the compiler. So current min. requirement is a compiler with at least C++14 support. Last year's release even compiled with pre-C++11 compilers. > parser.y: In function ‘int InstrScript_parse(LinuxSampler::ParserContext*)’: > parser.y:311:25: sorry, unimplemented: non-trivial designated initializers > not supported }); > ^ > parser.y:311:25: sorry, unimplemented: non-trivial designated initializers > not supported parser.y:311:25: sorry, unimplemented: non-trivial designated > initializers not supported parser.y:311:25: sorry, unimplemented: > non-trivial designated initializers not supported parser.y:318:26: sorry, > unimplemented: non-trivial designated initializers not supported }); > ^ > > There is a whole bunch more of these "sorry, unimplemented..." lines on the > same file. Bison version is 3.0.4. > > I rebuilt&installed current libgig/liblscp packages before building this > one, all fine so far. > > Do I have to run some manual "generate" step first? Short: either compile with clang (works also with quite old versions of clang) or update to GCC >= 8.x. You can install both clang and gcc without problems. If you have both installed, just force LS compilation with clang like this: CXX=clang++ CC=clang ./configure && make Background: The LS code base is now using a lot of so called "designated initializers", probably better described as C-style "named initializers" for semantic critical functions/methods. Instead of this: void foo(int a, float b, char c, bool d) { ... } ... foo(1, 2.9, 'a', true); // function call it's now (often) like this instead: struct FooOpt { int a; float b; char c; bool d; } void foo(FooOpt& opt) { ... } ... foo({ // function call .a = 1, .b = 2.9, .c = 'a', .d = true }); Reason: after a while (months, years, ...), arguments of functions/methods are typically changed, which can silently introduce bugs since the compiler only checks function calls for type correctness with the old function call style. By binding a function argument to a name, you are binding it to a specific semantic when calling the function, which the compiler would immediately recognize with an error if function's semantics were changed without updating all calls appropriately, and hence prevents such kind of bugs at compilation. It also makes the code more readable. I know C++>=14 requirement is quite a shift regarding backward compatibility of LS, but a bunch of new C++ language features reduce code complexity (and hence development time and bug affinity) significantly, and the LS code base is already quite large, so I decided to go for the "please use recent compilers" route after last year's release instead of investing a lot of time for supporting old compilers. CU Christian |
|
From: Frank N. <bea...@we...> - 2020-02-03 19:54:45
|
Hi Christian, > The build requirement has in fact changed after last year's release: > http://doc.linuxsampler.org/Release_Notes/LinuxSampler_2_1_1/ [..] > > Short: either compile with clang (works also with quite old versions of clang) > or update to GCC >= 8.x. You can install both clang and gcc without problems. > If you have both installed, just force LS compilation with clang like this: > > CXX=clang++ CC=clang ./configure && make Great, this actually worked; thanks a lot! With this (and installing/using clang-6), I was able to build LinuxSampler on my laptop (Mint 19.2, Tara), and it runs fine there. On the desktop PC I still have build issues, but it's running a much older Mint version (18.2 "Sonya", with gcc 5.4.0) which I'll soon update anyway, so it's perhaps not worth the time/effort. You might still want to add these explanations to LinuxSampler's README.txt; I can imagine I am not the only one tripping over this. > > Background: The LS code base is now using a lot of so called "designated > initializers", probably better described as C-style "named initializers" for > semantic critical functions/methods. Instead of this: [..] Thanks for this insightful&instructional explanation. While I am no C++ developer, I fully understand your point. Greetings, Frank (who now actually started discovering nksp :-) |
|
From: Christian S. <sch...@li...> - 2020-02-04 15:13:16
|
On Montag, 3. Februar 2020 20:54:31 CET Frank Neumann wrote: > Hi Christian, > > > The build requirement has in fact changed after last year's release: > > http://doc.linuxsampler.org/Release_Notes/LinuxSampler_2_1_1/ > > [..] > > > Short: either compile with clang (works also with quite old versions of > > clang) or update to GCC >= 8.x. You can install both clang and gcc > > without problems.> > > If you have both installed, just force LS compilation with clang like this: > > CXX=clang++ CC=clang ./configure && make > > Great, this actually worked; thanks a lot! > With this (and installing/using clang-6), I was able to build LinuxSampler > on my laptop (Mint 19.2, Tara), and it runs fine there. > On the desktop PC I still have build issues, but it's running a much older > Mint version (18.2 "Sonya", with gcc 5.4.0) which I'll soon update anyway, > so it's perhaps not worth the time/effort. > > You might still want to add these explanations to LinuxSampler's README.txt; > I can imagine I am not the only one tripping over this. Sure, towards next release that will be updated appropriately. In the meantime I just added a configure check, which should make this clear: http://svn.linuxsampler.org/cgi-bin/viewvc.cgi/linuxsampler/trunk/configure.ac?r1=3739&r2=3738&pathrev=3739 My current assumption is that this issure requires GCC >= 8 or clang >= 5. I am not fully sure though. > > Background: The LS code base is now using a lot of so called "designated > > initializers", probably better described as C-style "named initializers" > > for > > semantic critical functions/methods. Instead of this: > [..] > > Thanks for this insightful&instructional explanation. While I am no C++ > developer, I fully understand your point. Designated initializers are actually an invention by the C language, where it is very heavily used by C developers. C++ just adopted this language feature after having it neglected for almost 3 decades. > Greetings, > Frank (who now actually started discovering nksp :-) Have you by chance heard about any news on the MIDI 2.0 front? Anybody working on kernel or ALSA support? Looks very promising (e.g. bidirectional communication, feature support negotiation between MIDI devices, setup presets and much more). Official announcement of MIDI 2.0 by MMA was on January 27th. CU Christian |
|
From: Frank N. <bea...@we...> - 2020-02-25 22:02:29
|
Hi Christian and all, On Tue, 04 Feb 2020 16:13:02 +0100 you wrote (sorry for the late reply): > Designated initializers are actually an invention by the C language, where it > is very heavily used by C developers. C++ just adopted this language feature > after having it neglected for almost 3 decades. > > > Greetings, > > Frank (who now actually started discovering nksp :-) > > Have you by chance heard about any news on the MIDI 2.0 front? Anybody working > on kernel or ALSA support? Looks very promising (e.g. bidirectional > communication, feature support negotiation between MIDI devices, setup presets > and much more). Official announcement of MIDI 2.0 by MMA was on January 27th. I'm not aware of any such efforts, but I don't monitor the current development of ALSA or most applications very closely. However, just today I saw that the MIDI 2.0 specs are now out, and individuals can even get them for free (registration required, though): http://www.synthtopia.com/content/2020/02/24/midi-2-0-specs-now-available-for-download/ 'thought you might want to know. Greetings, Frank |
|
From: Christian S. <sch...@li...> - 2020-02-29 18:23:24
|
On Dienstag, 25. Februar 2020 23:02:16 CET you wrote: > Hi Christian and all, > > On Tue, 04 Feb 2020 16:13:02 +0100 you wrote (sorry for the late reply): > > Designated initializers are actually an invention by the C language, where > > it is very heavily used by C developers. C++ just adopted this language > > feature after having it neglected for almost 3 decades. > > > > > Greetings, > > > Frank (who now actually started discovering nksp :-) > > > > Have you by chance heard about any news on the MIDI 2.0 front? Anybody > > working on kernel or ALSA support? Looks very promising (e.g. > > bidirectional communication, feature support negotiation between MIDI > > devices, setup presets and much more). Official announcement of MIDI 2.0 > > by MMA was on January 27th. > I'm not aware of any such efforts, but I don't monitor the current > development of ALSA or most applications very closely. I see, times changed. :) > However, just today I saw that the MIDI 2.0 specs are now out, and > individuals can even get them for free (registration required, though): > http://www.synthtopia.com/content/2020/02/24/midi-2-0-specs-now-available-fo > r-download/ > > 'thought you might want to know. Yeah, I've got that as well. I just thought you were still actively involved in LAD issues to some extent. CU Christian |