LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   can't install DBD::Sybase produces error (http://www.linuxquestions.org/questions/linux-software-2/cant-install-dbd-sybase-produces-error-915070/)

Majed17 11-23-2011 05:29 AM

can't install DBD::Sybase produces error
 
here is the error after i type
Code:


perl -MCPAN -e shell

Code:


cpan shell -- CPAN exploration and modules installation (v1.9456)
Enter 'h' for help.

cpan[1]> install DBD::Sybase
Going to read '/root/.cpan/Metadata'
  Database was generated on Tue, 22 Nov 2011 13:27:18 GMT
Running install for module 'DBD::Sybase'
Running make for M/ME/MEWP/DBD-Sybase-1.14.tar.gz
Checksum for /root/.cpan/sources/authors/id/M/ME/MEWP/DBD-Sybase-1.14.tar.gz ok
Scanning cache /root/.cpan/build for sizes
............................................................................DONE

  CPAN.pm: Going to build M/ME/MEWP/DBD-Sybase-1.14.tar.gz

Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.
Warning: No success on command[/usr/bin/perl Makefile.PL INSTALLDIRS=site]
'YAML' not installed, will not store persistent state
  MEWP/DBD-Sybase-1.14.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- NOT OK
Running make test
  Make had some problems, won't test
Running make install
  Make had some problems, won't install
Failed during this command:
 MEWP/DBD-Sybase-1.14.tar.gz                  : writemakefile NO '/usr/bin/perl Makefile.PL INSTALLDIRS=site' returned status 512

any idea what the problem is and what can be done? thanks for any help

TB0ne 11-24-2011 07:07 PM

Quote:

Originally Posted by Majed17 (Post 4531509)
here is the error after i type
Code:


perl -MCPAN -e shell

Code:


cpan shell -- CPAN exploration and modules installation (v1.9456)
Enter 'h' for help.

cpan[1]> install DBD::Sybase
Going to read '/root/.cpan/Metadata'
  Database was generated on Tue, 22 Nov 2011 13:27:18 GMT
Running install for module 'DBD::Sybase'
Running make for M/ME/MEWP/DBD-Sybase-1.14.tar.gz
Checksum for /root/.cpan/sources/authors/id/M/ME/MEWP/DBD-Sybase-1.14.tar.gz ok
Scanning cache /root/.cpan/build for sizes
............................................................................DONE

  CPAN.pm: Going to build M/ME/MEWP/DBD-Sybase-1.14.tar.gz

Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.
Warning: No success on command[/usr/bin/perl Makefile.PL INSTALLDIRS=site]
'YAML' not installed, will not store persistent state
  MEWP/DBD-Sybase-1.14.tar.gz
  /usr/bin/perl Makefile.PL INSTALLDIRS=site -- NOT OK
Running make test
  Make had some problems, won't test
Running make install
  Make had some problems, won't install
Failed during this command:
 MEWP/DBD-Sybase-1.14.tar.gz                  : writemakefile NO '/usr/bin/perl Makefile.PL INSTALLDIRS=site' returned status 512

any idea what the problem is and what can be done? thanks for any help

Did you not read the error?? I bolded what you've got to do in the message above...do it. Set the SYBASE environment variable in the Makefile.PL as it says.

Majed17 11-24-2011 11:56 PM

well if i did understand the error i would have solved it. i guess the environmental variable is set by : export command.
anyway i've getting support on another thread (http://forums.gentoo.org/viewtopic-p...6.html#6882306) but it hasn't worked so far.

i last tried:

Code:

srvmon-Bellakt ~ # export SYBASE=/usr/local/freetds
You have new mail in /var/mail/root

then:
Code:

g-cpan -i DBD-Sybase
result:
Code:

>>> Emerging (1 of 1) perl-gcpan/DBD-Sybase-1.14 from x-g-cpan
 * DBD-Sybase-1.14.tar.gz RMD160 SHA1 SHA256 size ;-) ...                [ ok ]
>>> Unpacking source...
>>> Unpacking DBD-Sybase-1.14.tar.gz to /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work
>>> Source unpacked in /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work
>>> Preparing source in /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14 ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14 ...
 * Using ExtUtils::MakeMaker
 * perl Makefile.PL PREFIX=/usr INSTALLDIRS=vendor INSTALLMAN3DIR=none DESTDIR=/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/image/
Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.
 * ERROR: perl-gcpan/DBD-Sybase-1.14 failed (configure phase):
 *  Unable to build!
 *
 * Call stack:
 *    ebuild.sh, line  56:  Called src_configure
 *  environment, line 2561:  Called perl-module_src_configure
 *  environment, line 2229:  Called perl-module_src_prep
 *  environment, line 2301:  Called die
 * The specific snippet of code:
 *              perl Makefile.PL "$@" <<< "${pm_echovar}" || die "Unable to build!";
 *
 * If you need support, post the output of 'emerge --info =perl-gcpan/DBD-Sybase-1.14',
 * the complete build log and the output of 'emerge -pqv =perl-gcpan/DBD-Sybase-1.14'.
 * This ebuild is from an overlay named 'x-g-cpan': '/var/tmp/g-cpan/'
 * The complete build log is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/environment'.
 * S: '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14'

>>> Failed to emerge perl-gcpan/DBD-Sybase-1.14, Log file:

>>>  '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/build.log'

 * Messages for package perl-gcpan/DBD-Sybase-1.14:

 * ERROR: perl-gcpan/DBD-Sybase-1.14 failed (configure phase):
 *  Unable to build!
 *
 * Call stack:
 *    ebuild.sh, line  56:  Called src_configure
 *  environment, line 2561:  Called perl-module_src_configure
 *  environment, line 2229:  Called perl-module_src_prep
 *  environment, line 2301:  Called die
 * The specific snippet of code:
 *              perl Makefile.PL "$@" <<< "${pm_echovar}" || die "Unable to build!";
 *
 * If you need support, post the output of 'emerge --info =perl-gcpan/DBD-Sybase-1.14',
 * the complete build log and the output of 'emerge -pqv =perl-gcpan/DBD-Sybase-1.14'.
 * This ebuild is from an overlay named 'x-g-cpan': '/var/tmp/g-cpan/'
 * The complete build log is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/environment'.
 * S: '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14'

and thanks for the reply :)

TB0ne 11-25-2011 09:33 AM

Quote:

Originally Posted by Majed17 (Post 4533322)
well if i did understand the error i would have solved it. i guess the environmental variable is set by : export command.
anyway i've getting support on another thread (http://forums.gentoo.org/viewtopic-p...6.html#6882306) but it hasn't worked so far.

i last tried:

Code:

srvmon-Bellakt ~ # export SYBASE=/usr/local/freetds
You have new mail in /var/mail/root

then:
Code:

g-cpan -i DBD-Sybase
result:
Code:

>>> Emerging (1 of 1) perl-gcpan/DBD-Sybase-1.14 from x-g-cpan
 * DBD-Sybase-1.14.tar.gz RMD160 SHA1 SHA256 size ;-) ...                [ ok ]
>>> Unpacking source...
>>> Unpacking DBD-Sybase-1.14.tar.gz to /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work
>>> Source unpacked in /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work
>>> Preparing source in /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14 ...
>>> Source prepared.
>>> Configuring source in /var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14 ...
 * Using ExtUtils::MakeMaker
 * perl Makefile.PL PREFIX=/usr INSTALLDIRS=vendor INSTALLMAN3DIR=none DESTDIR=/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/image/
Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.
 * ERROR: perl-gcpan/DBD-Sybase-1.14 failed (configure phase):
 *  Unable to build!
 *
 * Call stack:
 *    ebuild.sh, line  56:  Called src_configure
 *  environment, line 2561:  Called perl-module_src_configure
 *  environment, line 2229:  Called perl-module_src_prep
 *  environment, line 2301:  Called die
 * The specific snippet of code:
 *              perl Makefile.PL "$@" <<< "${pm_echovar}" || die "Unable to build!";
 *
 * If you need support, post the output of 'emerge --info =perl-gcpan/DBD-Sybase-1.14',
 * the complete build log and the output of 'emerge -pqv =perl-gcpan/DBD-Sybase-1.14'.
 * This ebuild is from an overlay named 'x-g-cpan': '/var/tmp/g-cpan/'
 * The complete build log is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/environment'.
 * S: '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14'

>>> Failed to emerge perl-gcpan/DBD-Sybase-1.14, Log file:

>>>  '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/build.log'

 * Messages for package perl-gcpan/DBD-Sybase-1.14:

 * ERROR: perl-gcpan/DBD-Sybase-1.14 failed (configure phase):
 *  Unable to build!
 *
 * Call stack:
 *    ebuild.sh, line  56:  Called src_configure
 *  environment, line 2561:  Called perl-module_src_configure
 *  environment, line 2229:  Called perl-module_src_prep
 *  environment, line 2301:  Called die
 * The specific snippet of code:
 *              perl Makefile.PL "$@" <<< "${pm_echovar}" || die "Unable to build!";
 *
 * If you need support, post the output of 'emerge --info =perl-gcpan/DBD-Sybase-1.14',
 * the complete build log and the output of 'emerge -pqv =perl-gcpan/DBD-Sybase-1.14'.
 * This ebuild is from an overlay named 'x-g-cpan': '/var/tmp/g-cpan/'
 * The complete build log is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/build.log'.
 * The ebuild environment file is located at '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/temp/environment'.
 * S: '/var/tmp/portage/perl-gcpan/DBD-Sybase-1.14/work/DBD-Sybase-1.14'

and thanks for the reply :)

Great...so you didn't read the message? It specifically says (and you've posted it twice so far)
Quote:

Originally Posted by Majed17
Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.

Setting it at the command line will do nothing, since the program is specifically telling you to set it in the config file, or in the Makefile, and even tells you what line to change.

Follow the instructions the program is giving you.

Majed17 11-27-2011 11:34 PM

well there is nothing i can do about it. wheni type emerge i don't control the process of installation, it is all done automatically, i don't even know where this make.pl file is. maybe what you are suggesting is download the sybase from somewhere and then install it manually?

Majed17 11-27-2011 11:57 PM

i tired downloading sybase directly from http://search.cpan.org/dist/DBD-Sybase/Sybase.pm
then i untarred it and typed:
Code:

perl Makefile.PL
i imeediately got:
Code:

Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.
line 44: $ldflags = "-L$SYBASE/$libdir $ldflags" unless $^O eq 'VMS';
line 120: die
line 121: "Please set SYBASE in CONFIG, or set the \$SYBASE environment variable";

so how can the environment variable be set?

TB0ne 11-28-2011 08:37 AM

Quote:

Originally Posted by Majed17 (Post 4535909)
i tired downloading sybase directly from http://search.cpan.org/dist/DBD-Sybase/Sybase.pm
then i untarred it and typed:
Code:

perl Makefile.PL
i imeediately got:
Code:

Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44.
line 44: $ldflags = "-L$SYBASE/$libdir $ldflags" unless $^O eq 'VMS';
line 120: die
line 121: "Please set SYBASE in CONFIG, or set the \$SYBASE environment variable";

so how can the environment variable be set?

Really??? READ THE ERROR MESSAGE
Quote:

Originally Posted by Majed17
Please set SYBASE in CONFIG, or set the $SYBASE environment variable at Makefile.PL line 120, <IN> line 44

You've now posted it THREE TIMES. It specifically tells you what to set, and where. One more time: edit the CONFIG file and put it in there. I downloaded it and looked, and it's VERY clear where you need to put that in the CONFIG file.

Majed17 11-28-2011 11:52 PM

you're no help you're just trying to make fun of a newbie in linux. if i knew it was refering to the config file i would have opened it, i simply thought the environment variable should be set in line 44 in the makefile.pl and besides i don't know what the environmnet variable is hence i was repeating the question all the time, but it seems you don't know either.

TB0ne 11-29-2011 09:10 AM

Quote:

Originally Posted by Majed17 (Post 4537000)
you're no help you're just trying to make fun of a newbie in linux. if i knew it was refering to the config file i would have opened it, i simply thought the environment variable should be set in line 44 in the makefile.pl and besides i don't know what the environmnet variable is hence i was repeating the question all the time, but it seems you don't know either.

Not making fun of anyone, but the message TELLS YOU what to edit. There is a file in the directory called CONFIG...the same one on the message that you posted three times in a row.

So:
  • Go into the directory you'll have after unzipping the .tar.gz file
  • See the file called CONFIG? Open it in whatever editor you want.
  • Go to LINE 10...the VERY FIRST VARIABLE, beneath a VERY CLEAR COMMENT
  • Change it to be whatever you'd like
  • Save the file
  • Run "perl Makefile.PL"
The error message has told you what to do from the very beginning. Doesn't get much clearer than that, or much simpler. If you don't understand the answer, sorry...I can't make it simpler; I even downloaded it and gave you the line number this time. If you can't make the change, give these instructions to someone else at your organization.

Majed17 11-30-2011 02:04 AM

what you said is already obvious after i understood that "config" is a file. i already tried all this yesterday, but the million dollar guru question remains: what is the environment variable and it doesn't seem something like you know.
i tried
Code:

SYBASE=/usr/local/freetds
and
Code:

SYBASE=/usr/local
with the latter variable producing a new error:
Code:

srvmon-Bellakt DBD-Sybase-1.14 # perl Makefile.PL
Can't find any Sybase libraries in /usr/local//lib or /usr/local//lib64 at Makefile.PL line 147, <IN> line 47.

a google search for libs of sybase produced little beneficial result with one site saying to install sybase ase from a sybase user. but i don't know if i need all that for the module to work.
it seems you don't get that in gentoo you install programs through the emerge command and you i don't know the location of any config or makefile in the process and so the the error apeared 3 times in my posts. by the way when i type
Code:

export SYBASE=/usr/local
then echo $SYBASE is :
Code:

/usr/local/
which is the same as setting the config environmental variable in the config file.
this installation process is proving way to difficult perhaps there is a bug in this module.

Lastly, if i was in your place and i really wanted to help instead of showing that i know then i would have tried to install Sybase on my system!

TB0ne 11-30-2011 09:30 AM

Quote:

Originally Posted by Majed17 (Post 4537983)
what you said is already obvious after i understood that "config" is a file. i already tried all this yesterday, but the million dollar guru question remains: what is the environment variable and it doesn't seem something like you know.
i tried
Code:

SYBASE=/usr/local/freetds
and
Code:

SYBASE=/usr/local
with the latter variable producing a new error:
Code:

srvmon-Bellakt DBD-Sybase-1.14 # perl Makefile.PL
Can't find any Sybase libraries in /usr/local//lib or /usr/local//lib64 at Makefile.PL line 147, <IN> line 47.


Think. Why/how would ANYONE here know how you have your system set up? An environment variable can be ANYTHING...any path, any drive, anywhere that YOU set it up to be. YOU are the one who would know it. And again, you need to read (more importantly, UNDERSTAND) the messages. The package cannot find the Sybase development headers. GO INSTALL THEM...either get them from your online repos, or from Sybase.
Quote:

a google search for libs of sybase produced little beneficial result with one site saying to install sybase ase from a sybase user. but i don't know if i need all that for the module to work.
So documentation is telling you a step you need to take to install this...but you're ignoring it?
Quote:

it seems you don't get that in gentoo you install programs through the emerge command and you i don't know the location of any config or makefile in the process and so the the error apeared 3 times in my posts. by the way when i type
Code:

export SYBASE=/usr/local
then echo $SYBASE is :
Code:

/usr/local/
which is the same as setting the config environmental variable in the config file.
No, it is NOT the same. The config file needs it to be in there to perform the installation, since you're ignoring the documented step of installing it as a sybase user, that has ALL those variables set already. Your step one needs to be, "do a full sybase installation, and verify that it's working". And I 'get' that gentoo uses the emerge command...like RedHat distros use yum, and suse uses yast. But this is the FIRST TIME you mention your distro...have you looked in your online repositories for the perl module??
Quote:

this installation process is proving way to difficult perhaps there is a bug in this module. Lastly, if i was in your place and i really wanted to help instead of showing that i know then i would have tried to install Sybase on my system!
No, thanks...I have installed Sybase (and this module), several times on other systems. I don't need to do it again. Being nasty does not give anyone incentive to help you.

Majed17 12-27-2011 12:25 AM

i'm beginning to have doubts that you ever installed sybase as all you are doing is guessing. and i wasn't being nasty just frank. if you did ever install sybase and don't remember how then it is no help in posting replies that lead nowhere. in the end it turned out there is no need to install any sybase software or under any sybase user. and setting the right export command does set the right variable in config!
on the other forum some newbie registered and posted to try :

Code:

export SYBASE="/usr"
and after that the installation process magically worked :)
and i thought this should be posted to help future users from not stepping in the same hole.

TB0ne 12-27-2011 09:44 AM

Quote:

Originally Posted by Majed17 (Post 4559091)
i'm beginning to have doubts that you ever installed sybase as all you are doing is guessing. and i wasn't being nasty just frank. if you did ever install sybase and don't remember how then it is no help in posting replies that lead nowhere.

If you say so.
Quote:

in the end it turned out there is no need to install any sybase software or under any sybase user. and setting the right export command does set the right variable in config! on the other forum some newbie registered and posted to try :
Code:

export SYBASE="/usr"
and after that the installation process magically worked :) and i thought this should be posted to help future users from not stepping in the same hole.
Well, YOU were the one who said you wanted to load the Sybase software/module. The instructions were clear, as was the error message...sorry you couldn't follow them. Glad things are working for you.

mwclark4453 11-07-2013 10:11 AM

FreeTDS Devel package required
 
One final note for others stepping into this hole. You need to install both the freetds-devel as well as the freetds packages. If you installed freetds from source, you probably got everything automatically but if you used a package manager, add the development package to your install process.


All times are GMT -5. The time now is 11:20 AM.