MySQL 5.5.28 compile on AIX 7.1


 
Thread Tools Search this Thread
Operating Systems AIX MySQL 5.5.28 compile on AIX 7.1
# 1  
Old 11-05-2012
MySQL 5.5.28 compile on AIX 7.1

Hi,

I have an AIX 7.1 lpar with cmake, gmp, libmpc, mpfr on it and a gcc 4.6.2 compiler that was made with the no-dependency flag.
I am trying to complile MySql5.5.28 from Oracle. Cmake runs fine. Then when I run make, I get the following:
Code:
<nyissz>
Scanning dependencies of target strings
[  9%] Building C object strings/CMakeFiles/strings.dir/bchange.c.o
In file included from /prod/mysql/src/mysql-5.5.28/strings/bchange.c:27:0:
/prod/mysql/src/mysql-5.5.28/include/my_global.h: In function 'my_ulonglong2double':
/prod/mysql/src/mysql-5.5.28/include/my_global.h:289:74: error: expected ')' before 'A'
/prod/mysql/src/mysql-5.5.28/include/my_global.h:289:76: error: expected expression before ';' token
/prod/mysql/src/mysql-5.5.28/include/my_global.h:289:76: warning: control reaches end of non-void function [-Wreturn-type]
make: 1254-004 The error code from the last command is 1.


Stop.
make: 1254-004 The error code from the last command is 2.


Stop.
make: 1254-004 The error code from the last command is 2.


Stop.
<nyassz>

Looking at the my_global.h at around line 289, I see this:

<nyissz>
/* Go around some bugs in different OS and compilers */
#ifdef _AIX                     /* By soren@t.dk */
#define _H_STRINGS
#define _SYS_STREAM_H
/* #define _AIX32_CURSES */     /* XXX: this breaks AIX 4.3.3 (others?). */
#define ulonglong2double(A) my_ulonglong2double(A)
#define my_off_t2double(A)  my_ulonglong2double(A)
C_MODE_START
inline double my_ulonglong2double(unsigned long long A) { return (double A); }
C_MODE_END
#endif /* _AIX */

#ifdef HAVE_BROKEN_SNPRINTF     /* HPUX 10.20 don't have this defined */
#undef HAVE_SNPRINTF
#endif
#ifdef HAVE_BROKEN_PREAD
/*
<nyassz>

Exactly on this line dies make:
inline double my_ulonglong2double(unsigned long long A) { return (double A); }

Looking the definition of this inline function:
<nyissz>
Code:
#if !defined(_WIN64)
inline double my_ulonglong2double(unsigned long long value)
{
 long long nr=(long long) value;
 if (nr >= 0)
   return (double) nr;
 return (18446744073709551616.0 + (double) nr);
}
#define ulonglong2double my_ulonglong2double
#define my_off_t2double  my_ulonglong2double
#endif /* _WIN64 */

<nyassz>
I do not really see whre is the problem.

Any good hint ?
Thanks ahead,
János
Moderator's Comments:
Mod Comment Please use code tags next time for your code and data.

Last edited by vbe; 11-05-2012 at 02:34 PM.. Reason: code tags
# 2  
Old 11-05-2012
Check this blog post, the version doesn't match exactly, but the symptoms seem quite similar, it says to change:

Code:
inline double my_ulonglong2double(unsigned long long A) { return (double A); }

to
Code:
inline double my_ulonglong2double(unsigned long long A) { return ((double) A); }

# 3  
Old 11-09-2012
Hi Radoulov,

That took me from 9% to 65% :-) Thanks a lot. Now I have another problem with the compilation. Now the massage says:

Code:
[ 65%] Generating sql_yacc.cc, sql_yacc.h
        cd /prod/mysql/src/mysql-5.5.28/sql && /usr/bin/bison -y -p MYSQL --output=/prod/mysql/src/mysql-5.5.28/sql/sql_yacc.cc --defines=/prod/mysql/src/mysql-5.5.28/sql/sql_yacc.h /prod/mysql/src/mysql-5.5.28/sql/sql_yacc.yy
/usr/bin/m4: Not a recognized flag: -
Usage: m4 [-els] [-B Number] [-D Name[=Value]]... [-H Number]
       [-I Directory] [-S Number] [-T Number] [-U Name]... [File...] 
make: 1254-059 The signal code from the last command is 13.


Stop.
make: 1254-004 The error code from the last command is 2.


Stop.
make: 1254-004 The error code from the last command is 2.


Stop.

Any good hint ?
Thanks ahead,
János
# 4  
Old 11-09-2012
Trying to guess: could you try with GNU m4 and gcc?

Just curious: MySQL on AIX ...., why not Linux?
# 5  
Old 11-11-2012
Hi Radoulov,

I am using gcc 4.6.1:

Code:
{[root]palm:/:551}# gcc --version
gcc (GCC) 4.6.1

Looks like I already have the gcc version of m4,
Code:
{[root]palm:/:552}# find / -name m4 -print
/opt/freeware/bin/m4
/prod/gnutools/emacs-23.2/m4
/usr/bin/m4
/usr/ccs/bin/m4
/usr/linux/bin/m4
/usr/samples/tcpip/sendmail/m4

but the /usr/bin/m4 points to the IBM version of it:
Code:
{[root]palm:/:553}# ls -l /usr/bin/m4
lrwxrwxrwx    1 bin      bin              15 Jul 27 13:30 /usr/bin/m4 -> /usr/ccs/bin/m4

So, looks like I just have to modify the link. I will do it tomorrow, Monday and see how that goes.

The reason for AIX is, that it is "free" :-) We have a production server owned by the Hospital with all the /hardware/ support behind it and we already have mysql 5.1 on it. That was the latest officially supported version of mysql from Sun. Here folks do not want to jump to any other platform right now, because the support background is not there for them.

Thanks a lot,
János

Moderator's Comments:
Mod Comment Please view this code tag video for how to use code tags when posting code and data.
# 6  
Old 11-11-2012
Hi János,
instead of modifying the link to m4, you could try to modify the PATH.
Assuming the GNU m4 is in /usr/linux/bin, something like this may work (hopping not to break something else) :

Code:
export PATH=/usr/linux/bin:$PATH

However, as you already said, MySQL 5.5 is not supported on AIX, so I would suggest to use the latest supported version.
# 7  
Old 11-14-2012
Hi Radoulov,

I managed to get to 87% :-). I needed a newer m4 (1.4.16) and a newer libsigsegv (2.7). Now it dies here:
Code:
Linking CXX executable pfs-t
cd /prod/mysql/src/mysql-5.5.28/storage/perfschema/unittest && /usr/local/cmake-2.8.9-AIX-powerpc/bin/cmake -E cmake_link_script CMakeFiles/pfs-t.dir/link.txt --verbose=1
/usr/bin/c++    -Wall -Wno-unused-parameter -fno-implicit-templates -fno-exceptions -fno-rtti -O2 -g -DDBUG_OFF    CMakeFiles/pfs-t.dir/pfs-t.cc.o  -o pfs-t -Wl,-brtl,-bnoipath,-bexpfull -lpthread ../../../unittest/mytap/libmytap.a ../libperfschema.a ../../../mysys/libmysys.a ../../../dbug/libdbug.a ../../../mysys/libmysys.a ../../../dbug/libdbug.a ../../../strings/libstrings.a ../../../zlib/libzlib.a -lm -lpthread /opt/freeware/lib/gcc/powerpc-ibm-aix7.1.0.0/4.6.1/libgcc_eh.a /opt/freeware/lib/gcc/powerpc-ibm-aix7.1.0.0/4.6.1/libgcc_eh.a -Wl,-blibpath:/usr/lib:/lib 
ld: 0711-224 WARNING: Duplicate symbol: .my_ulonglong2double
ld: 0711-224 WARNING: Duplicate symbol: __fe_def_env
ld: 0711-224 WARNING: Duplicate symbol: my_ulonglong2double
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
ld: 0711-224 WARNING: Duplicate symbol: .my_ulonglong2double
ld: 0711-224 WARNING: Duplicate symbol: __fe_def_env
ld: 0711-224 WARNING: Duplicate symbol: my_ulonglong2double
ld: 0711-345 Use the -bloadmap or -bnoquiet option to obtain more information.
ld: 0711-317 ERROR: Undefined symbol: .sql_print_error(char const*, ...)
ld: 0711-317 ERROR: Undefined symbol: .Query_tables_list::destroy_query_tables_list()
ld: 0711-317 ERROR: Undefined symbol: .plugin_unlock_list(THD*, st_plugin_int**, unsigned int)
ld: 0711-317 ERROR: Undefined symbol: vtable for st_select_lex_node
ld: 0711-317 ERROR: Undefined symbol: .MDL_request::init(MDL_key::enum_mdl_namespace, char const*, char const*, enum_mdl_type, enum_mdl_duration)
ld: 0711-317 ERROR: Undefined symbol: .LEX::LEX()
ld: 0711-317 ERROR: Undefined symbol: .lex_start(THD*)
ld: 0711-317 ERROR: Undefined symbol: vtable for DML_prelocking_strategy
ld: 0711-317 ERROR: Undefined symbol: .open_and_lock_tables(THD*, TABLE_LIST*, bool, unsigned int, Prelocking_strategy*)
ld: 0711-317 ERROR: Undefined symbol: .Table_check_intact::check(TABLE*, st_table_field_def const*)
ld: 0711-317 ERROR: Undefined symbol: .close_thread_tables(THD*)
ld: 0711-317 ERROR: Undefined symbol: .lex_end(LEX*)
ld: 0711-317 ERROR: Undefined symbol: THR_THD
ld: 0711-317 ERROR: Undefined symbol: lower_case_table_names
ld: 0711-317 ERROR: Undefined symbol: .Field_enum::store_type(unsigned long long)
ld: 0711-317 ERROR: Undefined symbol: .ACL_internal_schema_registry::register_schema(st_mysql_lex_string const*, ACL_internal_schema_access const*)
ld: 0711-317 ERROR: Undefined symbol: key_map_empty
ld: 0711-317 ERROR: Undefined symbol: vtable for handler
ld: 0711-317 ERROR: Undefined symbol: .calculate_key_len(TABLE*, unsigned int, unsigned char const*, unsigned long)
ld: 0711-317 ERROR: Undefined symbol: .handler::print_error(int, int)
ld: 0711-317 ERROR: Undefined symbol: .handler::ha_statistic_increment(unsigned long system_status_var::*) const
ld: 0711-317 ERROR: Undefined symbol: .handler::ha_table_share_psi(TABLE_SHARE const*) const
ld: 0711-317 ERROR: Undefined symbol: handler::clone(char const*, st_mem_root*)
ld: 0711-317 ERROR: Undefined symbol: handler::get_error_message(int, String*)
ld: 0711-317 ERROR: Undefined symbol: handler::column_bitmaps_signal()
ld: 0711-317 ERROR: Undefined symbol: handler::index_read_idx_map(unsigned char*, unsigned int, unsigned char const*, unsigned long, ha_rkey_function)
ld: 0711-317 ERROR: Undefined symbol: handler::index_next_same(unsigned char*, unsigned char const*, unsigned int)
ld: 0711-317 ERROR: Undefined symbol: handler::read_multi_range_first(st_key_multi_range**, st_key_multi_range*, unsigned int, bool, st_handler_buffer*)
ld: 0711-317 ERROR: Undefined symbol: handler::read_multi_range_next(st_key_multi_range**)
ld: 0711-317 ERROR: Undefined symbol: handler::read_range_first(st_key_range const*, st_key_range const*, bool, bool)
ld: 0711-317 ERROR: Undefined symbol: handler::read_range_next()
ld: 0711-317 ERROR: Undefined symbol: handler::read_first_row(unsigned char*, unsigned int)
ld: 0711-317 ERROR: Undefined symbol: handler::get_dynamic_partition_info(PARTITION_STATS*, unsigned int)
ld: 0711-317 ERROR: Undefined symbol: handler::get_auto_increment(unsigned long long, unsigned long long, unsigned long long, unsigned long long*, unsigned long long*)
ld: 0711-317 ERROR: Undefined symbol: handler::drop_table(char const*)
collect2: ld returned 8 exit status
gmake[2]: *** [storage/perfschema/unittest/pfs-t] Error 1
gmake[2]: Leaving directory `/prod/mysql/src/mysql-5.5.28'
gmake[1]: *** [storage/perfschema/unittest/CMakeFiles/pfs-t.dir/all] Error 2
gmake[1]: Leaving directory `/prod/mysql/src/mysql-5.5.28'
gmake: *** [all] Error 2
{

Any good hint ? /I started to google for the errors, but looks like pfs-t has the issue.

Thanks ahead,
János
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Red Hat

I want to install/compile php with mysql.

I have removed php-5.1.6-27.el5 from our system. Because I installed it without mysql before. How can I install php together with mysql. # rpm -qa | grep mysql* libdbi-dbd-mysql-0.8.1a-1.2.2 mysql-5.0.77-4.el5_4.2 mysql-server-5.0.77-4.el5_4.2 mysql-connector-odbc-3.51.26r1127-1.el5 ##... (5 Replies)
Discussion started by: getrue
5 Replies

2. Solaris

Compile PHP 5.3.6 with MySql on Sun Blade 1500 Solaris 10

Hello, I'm trying to compile PHP 5.3.6 with Apache2 and MySql 5.5.12. I hit a problem that I can't seem to resolve by myself and I could not find a solution on the web. It looks like Apache and MySql installed ok, I can start/stop them with no problem. When I try to compile PHP the... (4 Replies)
Discussion started by: pn8830
4 Replies

3. AIX

Compile PHP on AIX 5.2 Error

Hello, I am trying to compile PHP 5.3.5 on AIX 5.2 with Apache 2.2.17 and Mysql 3.23.58 Apache und Mysql are working fine but if i try to compile PHP i get this error: with make: sapi/apache2handler/php_functions.lo main/internal_functions.lo -lmysqlclient -lfreetype -lX11 -lXpm -lpng -lz... (2 Replies)
Discussion started by: dtiger
2 Replies

4. Programming

Can someone compile and run a program on AIX 6.1 please?

Hi, I have a program which collects performance data from AIX. It works fine on older releases (< 5.3) but I fail to get data from /proc. I would really appreciate it if someone could compile (using ANSI compat C compiler), run the program (for 30-40 minutes) on AIX 6.1 and send me the... (2 Replies)
Discussion started by: StuBob
2 Replies

5. Solaris

DBI with MySQL client library compile on Solaris

how dow you complie perl module DBI with mysql from /usr/local/mysql/bin keeps going to mysql client for /usr/sfw/bin is it the LD_PATH ???...:confused: error is # perl login.cgi DBI connect('customers;mysql_socket=/tmp/mysql.sock:localhost','root',...) failed: Client does not... (1 Reply)
Discussion started by: photon
1 Replies

6. Solaris

Errors trying to compile PHP for use with MySQL on Solaris 10

have installed and am using the GNU based tools from the Sunfreeware site to compile PHP. I already have Apache, MySQL, and Oracle compiled and working properly. Below is my configure string for my PHP build: ./configure --prefix=/usr/local/php5 \... (2 Replies)
Discussion started by: sunsysadm2003
2 Replies

7. AIX

Error when compile httpd 2.2.8 on AIX 5.2

Hi everybody, I tried to compile httpd-2.8.8 on AIX 5.2. After downloading the Source file I run the configure as following: >> CC=gcc ./configure --prefix=/usr/local/apache After that i run the command make, but it failed. Below are last several lines of stdout of the make command: lo... (7 Replies)
Discussion started by: aldowsary
7 Replies

8. AIX

Compile gcc on AIX 5.2

I'm trying to compile gcc 3.4.6 on AIX 5.2 but I get this error: bison -t --name-prefix=java_ -o java/parse.c java/parse.y M4sugar requires GNU M4. Install it before installing M4sugar or set the M4 environment variable to its path name.make: *** Broken pipe gcc -c -g -O2 -DIN_GCC -W... (7 Replies)
Discussion started by: untamed
7 Replies

9. Solaris

error: compile 64 bit mysql on Solaris 10

I'm trying to build 64 bit mysql-5.0.37 on Solaris 10. CFLAGS="-O3" CXX='gcc -m64 -mcpu=v9' CXXFLAGS="-O3 -felide-constructors -fno-exceptions -fno-rtti" ./configure -disable-shared --prefix=/usr/local/mysql --datadir=/home1/mysql_data --with-mysqld-user=mysql ... (0 Replies)
Discussion started by: csross
0 Replies

10. Programming

compile problem on aix

When compiling (a simple test program): #include <stdio.h> #include <sys/context.h> int main() { printf("Hello\n"); return 0; } on AIX 5.2 with gcc 3.2.2 from the IBM site I get the following error: /usr/include/sys/context.h:169: parse error before "sigset64_t"... (4 Replies)
Discussion started by: rein
4 Replies
Login or Register to Ask a Question