MySQL Lists are EOL. Please join:

List:Internals« Previous MessageNext Message »
From:Paul Green Date:May 24 2006 3:02pm
Subject:Patches to correct build issues on Stratus VOS
View as plain text  
Hello,

I am a software developer at Stratus Technologies and I have just spent
a few days porting MySQL to the Stratus VOS environment. I used our
POSIX-based "OpenVOS" environment running under VOS Release 15.2.dev.fa
on a Stratus V200 system. This is an Intel Pentium4 Xeon processor
running code in Big Endian format (for compatibility with our older
PA-RISC systems).

I'm enclosing uni-diffs against revision 1.2105 (5.0.21) for the build
issues that I had to correct.  There were some other issues with missing
features / functions in our own environment; I won't bore you with those
details.

At this point MySQL builds without errors. I haven't had a chance to run
the tests yet.  If running the tests uncovers new issues, I'll send in
further patches.

I have to say that despite its enormous size, porting the MySQL source
code to VOS was very straightforward. The issues were minor and
resolving them was simple.  Thanks for the effort that you put into
this; I know it can't have been easy.

Here is a summary of what I changed.

1. mysql/configure.in -- added a special-case for the PS command on VOS.
2. mysql/cmd-line-utils/libedit/(el.c sig.c sig.h term.c) -- made
SIGWINCH optional.
3. mysql/dbug/Makefile.in -- added support for an executable extension.
4. mysql/include/my_global.h -- avoided i386 special case on big-endian
systems b/c it is only valid for little-endian environments
5. mysql/server-tools/instance-manager/instance_options.cc -- included
netdb.h, to pull in the prototype for gethostname.

I don't have enough experience with the MySQL source code organization
to know whether the reference to <netdb.h> should be in
instance_options.cc or in another header.  Please do what you think is
appropriate.

To my eyes, most of these items are fairly general issues which could
potentially affect other platforms.  But I understand that accepting and
applying patches is a judgement call, so I'll understand if you only
take some of them.  None of them were particularly difficult to discover
or work around.

If you have any questions or comments, please let me know.

 <<diff_mysql_vos.txt>> 

Thanks
PG
--
Paul Green, Senior Technical Consultant, Stratus Technologies.
Voice: +1 978-461-7557; FAX: +1 978-461-3610; Mobile: +1 (978) 235-2451;
AIM: PaulGreen


Attachment: [text/html]
Attachment: [text/html]
diff -u /subversion/mysql/configure.in.orig /subversion/mysql/configure.in --- /subversion/mysql/configure.in.orig 2006-04-26 14:31:03.000000000 -0400 +++ /subversion/mysql/configure.in 2006-05-24 10:09:54.000000000 -0400 @@ -479,6 +479,9 @@ *netware*) FIND_PROC= ;; + *stratus-vos*) + FIND_PROC="$PS p \$\$PID | grep -v grep | grep \$\$MYSQLD > /dev/null" + ;; *) AC_MSG_ERROR([Could not find the right ps switches. Which OS is this ?. See the Installation chapter in the Reference Manual.]) esac diff -u /subversion/mysql/cmd-line-utils/libedit/el.c.orig /subversion/mysql/cmd-line-utils/libedit/el.c --- /subversion/mysql/cmd-line-utils/libedit/el.c.orig 2006-04-26 14:31:03.000000000 -0400 +++ /subversion/mysql/cmd-line-utils/libedit/el.c 2006-05-20 16:51:00.000000000 -0400 @@ -477,7 +477,9 @@ sigset_t oset, nset; (void) sigemptyset(&nset); +#ifdef SIGWINCH (void) sigaddset(&nset, SIGWINCH); +#endif (void) sigprocmask(SIG_BLOCK, &nset, &oset); /* get the correct window size */ diff -u /subversion/mysql/cmd-line-utils/libedit/sig.c.orig /subversion/mysql/cmd-line-utils/libedit/sig.c --- /subversion/mysql/cmd-line-utils/libedit/sig.c.orig 2006-04-26 14:31:05.000000000 -0400 +++ /subversion/mysql/cmd-line-utils/libedit/sig.c 2006-05-20 16:51:39.000000000 -0400 @@ -76,9 +76,11 @@ term__flush(); break; +#ifdef SIGWINCH case SIGWINCH: el_resize(sel); break; +#endif default: tty_cookedmode(sel); diff -u /subversion/mysql/cmd-line-utils/libedit/sig.h.orig /subversion/mysql/cmd-line-utils/libedit/sig.h --- /subversion/mysql/cmd-line-utils/libedit/sig.h.orig 2006-04-26 14:30:54.000000000 -0400 +++ /subversion/mysql/cmd-line-utils/libedit/sig.h 2006-05-24 10:35:57.000000000 -0400 @@ -48,6 +48,12 @@ * Define here all the signals we are going to handle * The _DO macro is used to iterate in the source code */ +#ifdef SIGWINCH +#define _DO_SIGWINCH _DO(SIGWINCH) +#else +#define _DO_SIGWINCH +#endif + #define ALLSIGS \ _DO(SIGINT) \ _DO(SIGTSTP) \ @@ -56,7 +62,7 @@ _DO(SIGHUP) \ _DO(SIGTERM) \ _DO(SIGCONT) \ - _DO(SIGWINCH) + _DO_SIGWINCH typedef void (*el_signalhandler_t)(int); typedef el_signalhandler_t *el_signal_t; diff -u /subversion/mysql/cmd-line-utils/libedit/term.c.orig /subversion/mysql/cmd-line-utils/libedit/term.c --- /subversion/mysql/cmd-line-utils/libedit/term.c.orig 2006-04-26 14:30:47.000000000 -0400 +++ /subversion/mysql/cmd-line-utils/libedit/term.c 2006-05-20 16:51:50.000000000 -0400 @@ -889,7 +889,9 @@ int lins, cols; (void) sigemptyset(&nset); +#ifdef SIGWINCH (void) sigaddset(&nset, SIGWINCH); +#endif (void) sigprocmask(SIG_BLOCK, &nset, &oset); area = buf; diff -u /subversion/mysql/dbug/Makefile.in.orig /subversion/mysql/dbug/Makefile.in --- /subversion/mysql/dbug/Makefile.in.orig 2006-04-26 14:31:51.000000000 -0400 +++ /subversion/mysql/dbug/Makefile.in 2006-05-24 10:36:38.000000000 -0400 @@ -36,6 +36,7 @@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ VPATH = @srcdir@ +EXEEXT = @EXEEXT@ pkgdatadir = $(datadir)/@PACKAGE@ pkglibdir = $(libdir)/@PACKAGE@ pkgincludedir = $(includedir)/@PACKAGE@ @@ -702,19 +703,19 @@ user.ps: user.r $(NROFF_INC) -groff -mm user.r > $@ -output1.r: factorial +output1.r: factorial$(EXEEXT) ./factorial 1 2 3 4 5 | cat > $@ -output2.r: factorial +output2.r: factorial$(EXEEXT) ./factorial -\#t:o 2 3 | cat >$@ -output3.r: factorial +output3.r: factorial$(EXEEXT) ./factorial -\#d:t:o 3 | cat >$@ -output4.r: factorial +output4.r: factorial$(EXEEXT) ./factorial -\#d,result:o 4 | cat >$@ -output5.r: factorial +output5.r: factorial$(EXEEXT) ./factorial -\#d:f,factorial:F:L:o 3 | cat >$@ .c.r: @RM@ -f $@ diff -u /subversion/mysql/include/my_global.h.orig /subversion/mysql/include/my_global.h --- /subversion/mysql/include/my_global.h.orig 2006-04-26 14:30:38.000000000 -0400 +++ /subversion/mysql/include/my_global.h 2006-05-20 17:24:11.000000000 -0400 @@ -1012,7 +1012,7 @@ */ /* Optimized store functions for Intel x86 */ -#if defined(__i386__) && !defined(_WIN64) +#if defined(__i386__) && !defined(_WIN64) && !defined(WORDS_BIGENDIAN) #define sint2korr(A) (*((int16 *) (A))) #define sint3korr(A) ((int32) ((((uchar) (A)[2]) & 128) ? \ (((uint32) 255L << 24) | \ diff -u /subversion/mysql/server-tools/instance-manager/instance_options.cc.orig /subversion/mysql/server-tools/instance-manager/instance_options.cc --- /subversion/mysql/server-tools/instance-manager/instance_options.cc.orig 2006-04-26 14:30:55.000000000 -0400 +++ /subversion/mysql/server-tools/instance-manager/instance_options.cc 2006-05-24 09:24:43.000000000 -0400 @@ -24,6 +24,7 @@ #include "buffer.h" #include <my_sys.h> +#include <netdb.h> #include <signal.h> #include <m_string.h> Process finished.
Thread
Patches to correct build issues on Stratus VOSPaul Green24 May
  • Re: Patches to correct build issues on Stratus VOSSergei Golubchik26 May
RE: Patches to correct build issues on Stratus VOSPaul Green30 May
  • Re: Patches to correct build issues on Stratus VOSSergei Golubchik30 May
  • RE: Patches to correct build issues on Stratus VOSStewart Smith31 May
  • RE: Patches to correct build issues on Stratus VOSLenz Grimmer31 Aug
RE: Patches to correct build issues on Stratus VOSPaul Green1 Sep
  • RE: Patches to correct build issues on Stratus VOSLenz Grimmer1 Sep