Description:
There has always been a semaphore.h file but it was ignored till the latest patches to the OS. Now it needs the exact same fix as sched.h.
*** configure.in.org Fri May 14 00:53:30 2004
--- configure.in Sun Jul 25 05:10:42 2004
***************
*** 1271,1276 ****
with_named_thread="-lgthreads -lsocket -lgthreads"
# sched.h conflicts with fsu-threads
touch ./include/sched.h
# We must have gcc
if expr "$CC" : ".*gcc.*"
--- 1271,1277 ----
with_named_thread="-lgthreads -lsocket -lgthreads"
# sched.h conflicts with fsu-threads
touch ./include/sched.h
+ touch ./include/semaphore.h
# We must have gcc
if expr "$CC" : ".*gcc.*"
How to repeat:
Update OS to latest patches or updates. Then try to configure, make and build mysql. It For example on mysql-5.0.1-alpha it always fails with....
gcc -DDEFAULT_BASEDIR=\"/usr/local/mysql\" -DDATADIR="\"/usr/local/mysql/data\"" -DDEFAULT_CHARSET_HOME="\"/usr/local/mysql\"" -DSHAREDIR="\"/usr/local/mysql/share/mysql\"" -DHAVE_CONFIG_H -I. -I. -I.. -I../include -I. -O3 -DDBUG_OFF -O1 -belf -DSCO -belf -c `test -f 'my_semaphore.c' || echo './'`my_semaphore.c
In file included from ../include/my_semaphore.h:38,
from my_semaphore.c:23:
/usr/include/semaphore.h:42: syntax error before `*'
/usr/include/semaphore.h:43: syntax error before `*'
/usr/include/semaphore.h:44: syntax error before `*'
/usr/include/semaphore.h:44: warning: data definition has no type or storage class
/usr/include/semaphore.h:45: syntax error before `*'
/usr/include/semaphore.h:47: syntax error before `*'
/usr/include/semaphore.h:48: syntax error before `*'
/usr/include/semaphore.h:49: syntax error before `*'
/usr/include/semaphore.h:50: syntax error before `*'
gmake[2]: *** [my_semaphore.o] Error 1
gmake[2]: Leaving directory `/usr/zenez/build/osr507/mysql-5.0.1-alpha/mysys'
gmake[1]: *** [all-recursive] Error 1
gmake[1]: Leaving directory `/usr/zenez/build/osr507/mysql-5.0.1-alpha'
gmake: *** [all] Error 2
Suggested fix:
*** configure.in.org Fri May 14 00:53:30 2004
--- configure.in Sun Jul 25 05:10:42 2004
***************
*** 1271,1276 ****
with_named_thread="-lgthreads -lsocket -lgthreads"
# sched.h conflicts with fsu-threads
touch ./include/sched.h
# We must have gcc
if expr "$CC" : ".*gcc.*"
--- 1271,1277 ----
with_named_thread="-lgthreads -lsocket -lgthreads"
# sched.h conflicts with fsu-threads
touch ./include/sched.h
+ touch ./include/semaphore.h
# We must have gcc
if expr "$CC" : ".*gcc.*"