LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 09-29-2003, 05:09 PM   #1
nakkaya
LQ Guru
 
Registered: Jan 2003
Location: Turkey&USA
Distribution: Emacs and linux is its device driver(Slackware,redhat)
Posts: 1,398

Rep: Reputation: 45
compiling mysql++ on slackware


i download ed the mysql++ tar package from mysql.com
when i try to compile the package
i type automake

i get this error
configure.in:11: your implementation of AM_INIT_AUTOMAKE comes from an
configure.in:11: old Automake version. You should recreate aclocal.m4
configure.in:11: with aclocal and run automake again.
Makefile.am: required file `./COPYING' not found
Makefile.am: required file `./INSTALL' not found
Makefile.am: required file `./NEWS' not found
Makefile.am: required file `./AUTHORS' not found
Makefile.am: required file `./ChangeLog' not found
examples/Makefile.am: required file `./depcomp' not found
/usr/share/automake-1.7/am/depend2.am: am__fastdepCXX does not appear in AM_CONDITIONAL
/usr/share/automake-1.7/am/depend2.am: AMDEP does not appear in AM_CONDITIONAL
/usr/share/automake-1.7/am/depend2.am: am__fastdepCXX does not appear in AM_CONDITIONAL
/usr/share/automake-1.7/am/depend2.am: AMDEP does not appear in AM_CONDITIONAL

read me says run automake then autoconf then ./configure
does anyone know what am i doing wrong?
 
Old 09-30-2003, 12:10 AM   #2
lyle_s
Member
 
Registered: Jul 2003
Distribution: Slackware
Posts: 390

Rep: Reputation: 53
I downloaded mysql++-1.7.9.tar.gz to see what the problem is. Don't worry about the instructions saying to run automake and autoconf. There's a configure script there already, just run that. Just in case you don't already know, the sequence is:

./configure
make

then become root and do:

make install

Lyle
 
Old 10-01-2003, 08:10 PM   #3
nakkaya
LQ Guru
 
Registered: Jan 2003
Location: Turkey&USA
Distribution: Emacs and linux is its device driver(Slackware,redhat)
Posts: 1,398

Original Poster
Rep: Reputation: 45
you are rigth there is but after configure make gives errors...
 
Old 10-02-2003, 12:32 AM   #4
lyle_s
Member
 
Registered: Jul 2003
Distribution: Slackware
Posts: 390

Rep: Reputation: 53
What are the errors?

Lyle
 
Old 10-02-2003, 12:44 AM   #5
nakkaya
LQ Guru
 
Registered: Jan 2003
Location: Turkey&USA
Distribution: Emacs and linux is its device driver(Slackware,redhat)
Posts: 1,398

Original Poster
Rep: Reputation: 45
output of ./configure last lines
updating cache ./config.cache
creating ./config.status
creating Makefile
creating sqlplusint/Makefile
creating examples/Makefile
creating config.h
creating sqlplusint/exceptions.hh
sqlplusint/exceptions.hh is unchanged


then when i run make

this errors comes cant catch all of them

coldata2.hh:46: non-template type `mysql_ColData' used as a template
coldata2.hh:46: ISO C++ forbids declaration of `y' with no type
coldata2.hh:46: `ulonglong operator<<(long long unsigned int, int)' must have
an argument of class or enumerated type
coldata2.hh:46: non-template type `mysql_ColData' used as a template
coldata2.hh:46: ISO C++ forbids declaration of `x' with no type
coldata2.hh:46: `ulonglong operator>>(int, long long unsigned int)' must have
an argument of class or enumerated type
coldata2.hh:46: non-template type `mysql_ColData' used as a template
coldata2.hh:46: ISO C++ forbids declaration of `y' with no type
coldata2.hh:46: `ulonglong operator>>(long long unsigned int, int)' must have
an argument of class or enumerated type
In file included from coldata4.hh:6,
from coldata.cc:3:
coldata3.hh:17: non-template type `mysql_ColData' used as a template
coldata3.hh:17: non-member function `operator MysqlNull<T, B>()' cannot have `
const' method qualifier
coldata3.hh:17: `operator MysqlNull<T, B>()' must be a nonstatic member
function
coldata3.hh:17: `operator MysqlNull<T, B>()' must take exactly one argument
coldata3.hh:17: too many template parameter lists in declaration of `operator
MysqlNull<T, B>()'
coldata3.hh:17: syntax error before `{' token
In file included from coldata4.hh:8,
from coldata.cc:3:
string_util.hh:6: `string' was not declared in this scope
string_util.hh:6: `s' was not declared in this scope
string_util.hh:6: warning: `strip' initialized and declared `extern'
string_util.hh:6: variable or field `strip' declared void
string_util.hh:8: `string' was not declared in this scope
string_util.hh:8: `s' was not declared in this scope
string_util.hh:8: warning: `escape_string' initialized and declared `extern'
string_util.hh:8: variable or field `escape_string' declared void
string_util.hh:10: `string' was not declared in this scope
string_util.hh:10: `s' was not declared in this scope
string_util.hh:10: variable or field `str_to_upr' declared void
string_util.hh:10: `str_to_upr' declared as an `inline' variable
string_util.hh:10: syntax error before `{' token
string_util.hh:11: `s' was not declared in this scope
string_util.hh:11: syntax error before `;' token
string_util.hh:11: syntax error before `++' token
string_util.hh:12: `cnt' was not declared in this scope
string_util.hh:12: ISO C++ forbids declaration of `s' with no type
string_util.hh:12: `c' was not declared in this scope
string_util.hh:12: assignment (not initialization) in declaration
string_util.hh:13: syntax error before `}' token
string_util.hh:16: `string' was not declared in this scope
string_util.hh:16: `s' was not declared in this scope
string_util.hh:16: variable or field `str_to_lwr' declared void
string_util.hh:16: `str_to_lwr' declared as an `inline' variable
string_util.hh:16: syntax error before `{' token
string_util.hh:17: `s' was not declared in this scope
string_util.hh:17: syntax error before `;' token
string_util.hh:17: syntax error before `++' token
string_util.hh:18: `cnt' was not declared in this scope
string_util.hh:18: ISO C++ forbids declaration of `s' with no type
string_util.hh:18: `c' was not declared in this scope
string_util.hh:18: assignment (not initialization) in declaration
string_util.hh:19: syntax error before `}' token
string_util.hh:22: `string' was not declared in this scope
string_util.hh:22: `s' was not declared in this scope
string_util.hh:22: variable or field `strip_all_blanks' declared void
string_util.hh:22: `strip_all_blanks' declared as an `inline' variable
string_util.hh:22: syntax error before `{' token
string_util.hh:23: `s' was not declared in this scope
string_util.hh:23: syntax error before `;' token
string_util.hh:23: syntax error before `++' token
string_util.hh:24: syntax error before `--' token
string_util.hh:27: `string' was not declared in this scope
string_util.hh:27: `s' was not declared in this scope
string_util.hh:27: variable or field `strip_all_non_num' declared void
string_util.hh:27: `strip_all_non_num' declared as an `inline' variable
string_util.hh:27: syntax error before `{' token
string_util.hh:28: `s' was not declared in this scope
string_util.hh:28: syntax error before `;' token
string_util.hh:28: syntax error before `++' token
string_util.hh:29: syntax error before `--' token
In file included from coldata.cc:3:
coldata4.hh:11: non-template type `mysql_ColData' used as a template
coldata4.hh:11: non-member function `Type conv(Type)' cannot have `const'
method qualifier
coldata4.hh:11: too many template parameter lists in declaration of `Type
conv(Type)'
coldata4.hh:11: syntax error before `{' token
coldata4.hh:13: `strbuf' was not declared in this scope
coldata4.hh:13: ISO C++ forbids declaration of `strip_all_blanks' with no type
coldata4.hh:13: redefinition of `int strip_all_blanks'
string_util.hh:22: `int strip_all_blanks' previously defined here
coldata4.hh:14: `strbuf' was not declared in this scope
coldata4.hh:15: `strbuf' was not declared in this scope
coldata4.hh:17: syntax error before `=' token
coldata4.hh:20: syntax error before `==' token
coldata4.hh:20: syntax error before `++' token
coldata.cc:5: `string' was not declared in this scope
coldata.cc:5: non-template type `mysql_ColData' used as a template
coldata.cc:5: explicit instantiation of non-template type `<type error>'
coldata.cc:6: non-template type `mysql_ColData' used as a template
coldata.cc:6: explicit instantiation of non-template type `<type error>'
make[2]: *** [coldata.lo] Error 1
make[2]: Leaving directory `/home/nakkaya/mysql++-1.7.9/sqlplusint'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/home/nakkaya/mysql++-1.7.9'
make: *** [all-recursive-am] Error 2
 
Old 10-05-2003, 12:30 AM   #6
lyle_s
Member
 
Registered: Jul 2003
Distribution: Slackware
Posts: 390

Rep: Reputation: 53
If you look at http://www.mysql.com/downloads/api-mysql++.html you'll see some patches that need to be applied for it to compile on gcc 3.x.x.

Lyle
 
Old 10-05-2003, 01:28 AM   #7
nakkaya
LQ Guru
 
Registered: Jan 2003
Location: Turkey&USA
Distribution: Emacs and linux is its device driver(Slackware,redhat)
Posts: 1,398

Original Poster
Rep: Reputation: 45
i have never use a patch before what do i have to do with that .gz file and
do i need 3.3 patch or 3.x patch
 
Old 10-05-2003, 05:07 PM   #8
lyle_s
Member
 
Registered: Jul 2003
Distribution: Slackware
Posts: 390

Rep: Reputation: 53
See what your gcc version is by running:

gcc --version

I'm assuming that it's 3.2.2; if it's not, you may have to alter these instructions a little. You need autoconf, automake, and libtool installed (and maybe a few others that are slipping my mind).

First get "Patch for GCC 3.0", "Patch for GCC 3.2 (apply after 3.0 patch)", and "Patch for GCC 3.2.2" from http://www.mysql.com/downloads/api-mysql++.html. Save them in the same directory the source tarball is in.

Then follow what I did:

lyle@poole:~/temp$ ls
mysql++-1.7.9.tar.gz mysql++-gcc-3.2.2.patch.gz
mysql++-gcc-3.0.patch.gz mysql++-gcc-3.2.patch.gz

lyle@poole:~/temp$ tar xzf mysql++-1.7.9.tar.gz

lyle@poole:~/temp$ gunzip *patch.gz

lyle@poole:~/temp$ patch -p1 -d mysql++-1.7.9 < mysql++-gcc-3.0.patch
patching file examples/Makefile.in
patching file examples/cgi_image.cc
.
.
.
patching file sqlplusint/vallist.cc
patching file sqlplusint/vallist1.hh

lyle@poole:~/temp$ patch -p1 -d mysql++-1.7.9 < mysql++-gcc-3.2.patch
patching file configure.in
patching file sqlplusint/coldata1.hh
patching file sqlplusint/compare1.hh
patching file sqlplusint/connection.cc
patching file sqlplusint/exceptions.hh.in
patching file sqlplusint/null1.hh
patching file sqlplusint/null2.hh
patching file sqlplusint/set3.hh

lyle@poole:~/temp$ patch -p1 -d mysql++-1.7.9 < mysql++-gcc-3.2.2.patch
patching file sqlplusint/connection.cc
patching file sqlplusint/type_info1.hh

lyle@poole:~/temp$ cd mysql++-1.7.9

lyle@poole:~/temp/mysql++-1.7.9$ rm Makefile.in aclocal.m4 build.sh config.guess config.h config.status config.sub configure install-sh libtool ltconfig ltmain.sh missing mkinstalldirs stamp* examples/Makefile.in sqlplusint/Makefile.in

lyle@poole:~/temp/mysql++-1.7.9$ libtoolize
You should add the contents of `/usr/share/aclocal/libtool.m4' to `aclocal.m4'.

lyle@poole:~/temp/mysql++-1.7.9$ aclocal

lyle@poole:~/temp/mysql++-1.7.9$ autoconf

lyle@poole:~/temp/mysql++-1.7.9$ automake --foreign --add-missing
configure.in: installing `./install-sh'
configure.in: installing `./mkinstalldirs'
configure.in: installing `./missing'
examples/Makefile.am: installing `./depcomp'

lyle@poole:~/temp/mysql++-1.7.9$ ./configure
checking for a BSD-compatible install... /usr/bin/ginstall -c
checking whether build environment is sane... yes
.
.
.

config.status: creating sqlplusint/exceptions.hh
config.status: executing depfiles commands

lyle@poole:~/temp/mysql++-1.7.9$ make
.
.
.

lyle@poole:~/temp/mysql++-1.7.9$ su
Password:
root@poole:/home/lyle/temp/mysql++-1.7.9# make install
.
.
.

root@poole:/home/lyle/temp/mysql++-1.7.9# exit
exit
lyle@poole:~/temp/mysql++-1.7.9$

If the library works correctly, you can do what the mysql++ people should have done in the first place so their users wouldn't have to go through all this pain and suffering:

lyle@poole:~/temp/mysql++-1.7.9$ make dist
.
.
.

You'll find a source tarball called sqlplus-1.7.0.tar.gz in the current directory that you'll be able to use the old ./configure, make, make install sequence with.

Lyle
 
Old 11-21-2003, 12:32 PM   #9
Sajata
LQ Newbie
 
Registered: Nov 2003
Posts: 1

Rep: Reputation: 0
THANK YOU.

Thank you SO much, Lyle, for posting this help so simply - I've been trying to find the solution to this for ages. I'm pretty much a Linux newbie, and your post was an absolute godsend.

Thanks again.

Sarah
 
Old 02-18-2004, 03:54 PM   #10
songhome
LQ Newbie
 
Registered: Feb 2004
Posts: 2

Rep: Reputation: 0
Hi

I have reached to 'make' in the instructions from Lyle, and now I get the following errors. Can anybody help me?


linux:/usr/src/mysql++-1.7.9 # make
make all-recursive
make[1]: Entering directory `/usr/src/mysql++-1.7.9'
Making all in sqlplusint
make[2]: Entering directory `/usr/src/mysql++-1.7.9/sqlplusint'
make all-am
make[3]: Entering directory `/usr/src/mysql++-1.7.9/sqlplusint'
source='coldata.cc' object='coldata.lo' libtool=yes \
depfile='.deps/coldata.Plo' tmpdepfile='.deps/coldata.TPlo' \
depmode=gcc /bin/sh ../depcomp \
/bin/sh ../libtool --mode=compile g++ -DHAVE_CONFIG_H -I. -I. -I.. -I. -I../sqlplusint -I/usr/local/mysql/include/mysql -g -O2 -c -o coldata.lo `test -f coldata.cc || echo './'`coldata.cc
rm -f .libs/coldata.lo
g++ -DHAVE_CONFIG_H -I. -I. -I.. -I. -I../sqlplusint -I/usr/local/mysql/include/mysql -g -O2 -c coldata.cc -Wp,-MD,.deps/coldata.TPlo -fPIC -DPIC -o .libs/coldata.lo
In file included from coldata1.hh:10,
from coldata2.hh:5,
from coldata3.hh:12,
from coldata4.hh:6,
from coldata.cc:3:
null1.hh:4: ostream: No such file or directory
make[3]: *** [coldata.lo] Error 1
make[3]: Leaving directory `/usr/src/mysql++-1.7.9/sqlplusint'
make[2]: *** [all] Error 2
make[2]: Leaving directory `/usr/src/mysql++-1.7.9/sqlplusint'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/usr/src/mysql++-1.7.9'
make: *** [all] Error 2
 
Old 02-18-2004, 07:30 PM   #11
lyle_s
Member
 
Registered: Jul 2003
Distribution: Slackware
Posts: 390

Rep: Reputation: 53
It looks like the patches didn't apply correctly. Did the patch commands give any error messages?

You have to apply all three in the correct order.

Which version of gcc are you using?

Lyle

P.S. Sajata: You're welcome!
 
Old 02-19-2004, 11:58 AM   #12
songhome
LQ Newbie
 
Registered: Feb 2004
Posts: 2

Rep: Reputation: 0
Hi Lyle

I have solved the problem, by uncommenting some lines about iostream.

Thank you anyway, for your quick response!!!

Songhome
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Error compiling perl-DBD-MySQL after upgrading to MySQL 4.1 pitaro920 Linux - Software 1 01-16-2006 05:28 PM
Installing and compiling MySQL foo_mulan Linux - Newbie 13 07-21-2004 02:37 AM
IMAP compiling with Mysql support. sixth_sense Linux - Software 3 05-08-2004 04:57 PM
having trouble compiling MySQL on Slackware 9 fireman949 Linux - Software 1 01-15-2004 02:15 PM
Compiling Postfix/MySQL hypernetics Linux - Software 0 12-15-2003 02:43 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 08:16 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration