Current midas does not compile under gcc 4.8.4
Compiling the develop branch under Scientific Linux 5.1 with gcc 4.8.4, I get the errors
src/system.c: In function 'ss_mutex_create':
src/system.c:2716:10: warning: implicit declaration of function 'pthread_mutexattr_settype' [-Wimplicit-function-declaration]
status = pthread_mutexattr_settype(attr, PTHREAD_MUTEX_RECURSIVE);
^
src/system.c:2716:51: error: 'PTHREAD_MUTEX_RECURSIVE' undeclared (first use in this function)
status = pthread_mutexattr_settype(attr, PTHREAD_MUTEX_RECURSIVE);
^
src/system.c:2716:51: note: each undeclared identifier is reported only once for each function it appears in
Googling this error, I find under
that one needs to define
#define _POSIX_C_SOURCE 200112L
to use the advanced pthread features such as pthread_mutexattr_settype. If I define this variable, I get
/usr/include/sys/ipc.h:25:3: warning: #warning "Files using this header must be compiled with _SVID_SOURCE or _XOPEN_SOURCE" [-Wcpp]
# warning "Files using this header must be compiled with _SVID_SOURCE or _XOPEN_SOURCE"
^
and tons of other errors.
So at the moment I cannot compile midas and have to revert to some older version. This is a show stopper for me.
Comments (9)
-
-
reporter #! [meg@megon ~]$ cat /etc/redhat-release Scientific Linux SL release 5.1 (Boron)
You need any other information?
-
according to https://access.redhat.com/support/policy/updates/errata el5 is "end-of-life". It is also very old. I am not even sure if it has recursive mutexes implemented. Do we must support this? How many experiments you have running on el5? Why they cannot be upgraded to current linux distributions? What if we support just a subset of midas "to run a frontend" (no LOCAL_ROUTINES)? I will bring these questions to the midas forum, best discuss this problem there. K.O.
-
just looked around, I do not have any el5 computers remaining at triumf. I am not sure I can support midas on el5. There is no way you can move to a non-obsolete linux? I will look for an el5 machine some more... K.O.
-
gah!!! release 5.1, with no updates, security fixes, and with gcc 4.8.4 grafted into it? Even if I find an el5 machine, it will be el5.latest with stock gcc. If you want me to help with midas on such a non-standard linux, you will have to give me shell access. K.O.
-
message on the midas forum went out. if you do not mind, please explain why you still have sl5.1 (gah, not even 5.2!!!) and why you cannot move to an up-to-date linux. I understand that things have to be the way they have to be, but I am very curious about the "why" of it. K.O.
-
BTW, I do not like the idea of recursive locks, I now know how to restructure odb to remove the recursive locks (semaphore and mutex, both), but it is not a 5 minute project. If we want to do it, it will be more like January-ish. K.O.
-
reporter Well, we are in the middle of a running experiment in data taking phase. I would like to update midas to test it in a production environment. Can pause for half an hour, but not a day for an OS reinstall. But don’t worry, can do that next year during the shutdown. Just miss s good testing occasion.
Stefan
-
- changed status to wontfix
gcc 4.4.7 (el6), gcc 4.8.5 (el7) and gcc 6.3.0 (ubuntu) is ok. your linux is too old. K.O.
- Log in to comment
hopefully, it is sl5.11, not sl5.1. please confirm. K.O.