For Programmers: Free Programming Magazines  


Home > Archive > PHP Installation > November 2004 > RE: [PHP-INSTALL] payflow pro configure









You are viewing an archived Text-only version of the thread. To view this thread in it's original format and/or if you want to reply to this thread please [click here]

 

Author RE: [PHP-INSTALL] payflow pro configure
Sarah

2004-11-22, 3:56 pm

Hi Chuck,
If I get the compiler then the configure command will
work correctly? Is it easy to install the compiler?
Could I put the configure and make commands into a
file and then do a php exec to run it?

Thanks,
Sarah

--- Chuck Ouellette <chuck@wncg.net> wrote:

> After you run configure still being in your "PHP
> Source" directory just
> type "make" if that compiles without errors type in
> "make install" and
> that will install your new binaries in there
> respective directories.
> You need to make sure you have a current version of
> "make" and a GNU gcc
> compiler installed.
>
> -----Original Message-----
> From: Sarah [mailto:tiggrstaar@yahoo.com]
> Sent: Monday, November 22, 2004 11:03 AM
> To: php-install@lists.php.net
> Subject: [PHP-INSTALL] payflow pro configure
>
> Hi,
> I think I'm pretty close to getting this working but
> I
> rarely do configurations on unix systems so I'm
> stuck
> right now. I've built the code to take in the credit
> card information along with a page to process it
> with
> the payflow pro functions but I can't test because
> php
> isn't configured for it yet. The actual .so and .h
> files are in their proper directories I just don't
> have a good graspe on how to run the ./configure
> command and then do the php make afterwards. I have
> access to run commands and the right permissions but
> I
> don't know exactly where to run the configure and
> make
> commands along with their syntax.
>
> Here's what I tried:
> - went to /usr/lib/php4 and did ./configure
> --with-pfpro=/directory/where/payflow/is/installed
>
> - then i couldn't figure out the make part
>
> I'm sure this is probably simple for some people so
> if
> you could help steer me in the right direction it
> would really help me.
>
> Thanks,
> Sarah
>
>
>
>

Chris Hewitt

2004-11-22, 3:56 pm

On Mon, 2004-11-22 at 16:10, Sarah wrote:[color=darkred]
> Hi Chuck,
> If I get the compiler then the configure command will
> work correctly? Is it easy to install the compiler?
> Could I put the configure and make commands into a
> file and then do a php exec to run it?
>
> Thanks,
> Sarah
>
> --- Chuck Ouellette <chuck@wncg.net> wrote:
>

Sarah,

It is just as Chuck says. What OS are you using? Assuming its a
GNU/Linux then the normal compiler is gcc. You can check you have it by
doing "which gcc" (this returns the path to the compiler, here it is
/usr/bin/gcc). If you are on Solaris then the compiler is cc so do a
"which cc".

I would be surprised if you do not need more options to your configure
line. Do you just need payflow pro or other extensions like a database?
Is a previous version of PHP already installed? If so you can put a
phpinfo.php file (containing just "<?php phpinfo(); ?>" under you
document root directory and look at the output. It will give the
configure options used.

HTH
Chris
Sarah

2004-11-22, 3:56 pm

I believe the server is Redhat linux. I'm just helping
out with something so I'm new to this particular
server also. I did which cc and got "/usr/bin/cc".

The server has php4 installed along with mysql and
several other options. Really the only thing needed is
the payflow pro functions.

Just so I'm clear on what I need to do, does this
sound right?

1.) go to usr/bin/cc and type in the configure command
from my previous email or is there a way to reference
the compiler directory in my configure command?

2.) after that go to the php directory and type in
make install? BTW I'm not certain what the php
directory will look like because the best candidate I
found was one directory that only a php file with no
extension. I also found one where the sessions were
kept. Also what's typical php installation directory?
PHP definately is working on the server so I know
that's ok.

3.) Do I need to add anything to the php.ini file or
will everything be all set once the configure and make
is done?

Thanks for your help,
Sarah


--- Chris Hewitt <phpinst@manordata.uklinux.net>
wrote:

> On Mon, 2004-11-22 at 16:10, Sarah wrote:
> will
> compiler?
> in
> of
>
> Sarah,
>
> It is just as Chuck says. What OS are you using?
> Assuming its a
> GNU/Linux then the normal compiler is gcc. You can
> check you have it by
> doing "which gcc" (this returns the path to the
> compiler, here it is
> /usr/bin/gcc). If you are on Solaris then the
> compiler is cc so do a
> "which cc".
>
> I would be surprised if you do not need more options
> to your configure
> line. Do you just need payflow pro or other
> extensions like a database?
> Is a previous version of PHP already installed? If
> so you can put a
> phpinfo.php file (containing just "<?php phpinfo();
> ?>" under you
> document root directory and look at the output. It
> will give the
> configure options used.
>
> HTH
> Chris
>

Chris Hewitt

2004-11-22, 3:56 pm

On Mon, 2004-11-22 at 19:12, Sarah wrote:
> I believe the server is Redhat linux. I'm just helping
> out with something so I'm new to this particular
> server also. I did which cc and got "/usr/bin/cc".


This computer has Fedora Core 1 (effectively RedHat 10). It has cc and
gcc. I've not used cc but I would suggest gcc. As you probably have both
the configure/make will probably sort out what it needs.
>
> The server has php4 installed along with mysql and
> several other options. Really the only thing needed is
> the payflow pro functions.


Some of the configure options indicate the file layout so they can be
important. I would recommend noting the configure line in phpinfo()
anyway, even if you do not use it. The safest way is to use all the
existing options (changing any paths necessary) and add the payflow pro
option to it.
>
> Just so I'm clear on what I need to do, does this
> sound right?
>
> 1.) go to usr/bin/cc and type in the configure command
> from my previous email or is there a way to reference
> the compiler directory in my configure command?


Just go to the directory with the PHP source code. As the "which cc"
gave you an answer it is on your path so it will get picked up from
whatever directory you are in.
>
> 2.) after that go to the php directory and type in
> make install? BTW I'm not certain what the php
> directory will look like because the best candidate I
> found was one directory that only a php file with no
> extension. I also found one where the sessions were
> kept. Also what's typical php installation directory?
> PHP definately is working on the server so I know
> that's ok.


The source code you can put in any convenient directory. The resulting
binaries are subject to the configure options. There are three ways of
using PHP and you need to know which you want. Least likely is the
command line one only (CGI). If using apache httpd webserver most likely
is as an apache module (DSO). The third is to compile it into Apache
itself, which would mean compiling apache too. Your existing PHP
configure line will indicate which. If it has --with-apxs (or
--with-apxs2) then it is an apache DSO. The INSTALL file in the root PHP
source directory gives quite a lot of information.

The basic stages of most software is:
configure - set up options for compilation.
make - compile, using the configure options.
make install - put the resulting files int the right place. This stage
you would normally expect to be the root user for.
>
> 3.) Do I need to add anything to the php.ini file or
> will everything be all set once the configure and make
> is done?


Save your existing php.ini file. It is probably in /etc but again the
configure options may put it elsewhere. I'm not sure but the make
install may install a new one. You can overwite it with the old one
afterwards if you want to, or just merge the contents. I'm not aware of
any change needed for PHP 5 as opposed to 4. You will need to change
httpd.conf (assuming Apache), the INSTALL file will say how.
>
> Thanks for your help,
> Sarah


You are welcome. I should tell you that I have compiled PHP 5 here but I
do not use it (or payflow pro) but PHP 4.x. Also, others on this list
including Chuck will have information that I may not be aware of. YMMV.

Regards

Chris
Chris Hewitt

2004-11-22, 8:56 pm

On Mon, 2004-11-22 at 19:12, Sarah wrote:
> I believe the server is Redhat linux.

I forgot to mention, if you do "cat /etc/issue" it should tell you.

Chris
Sarah

2004-11-22, 8:56 pm

Ok well I just tried to run the configure command in
no particular directory and these are my results. Any
ideas?

> .configure --with

pfpro=/var/www/html/Verisign/verisign/payflowpro/linuxrh9/perl
sh: line 1: .configure: command not found

> ./configure

--with-pfpro=/var/www/html/Verisign/verisign/payflowpro/linuxrh9/perl
sh: line 1: ./configure: No such file or directory

The php bin directory is = /usr/bin.

What am I missing with the configure command? I tried
figuring out commands with cc but I didn't get very
far.

Thanks again for your help, I think I'm close to
getting this resolved.
Sarah

--- Chris Hewitt <phpinst@manordata.uklinux.net>
wrote:

> On Mon, 2004-11-22 at 19:12, Sarah wrote:
> helping
>
> This computer has Fedora Core 1 (effectively RedHat
> 10). It has cc and
> gcc. I've not used cc but I would suggest gcc. As
> you probably have both
> the configure/make will probably sort out what it
> needs.
> needed is
>
> Some of the configure options indicate the file
> layout so they can be
> important. I would recommend noting the configure
> line in phpinfo()
> anyway, even if you do not use it. The safest way is
> to use all the
> existing options (changing any paths necessary) and
> add the payflow pro
> option to it.
> command
> reference
>
> Just go to the directory with the PHP source code.
> As the "which cc"
> gave you an answer it is on your path so it will get
> picked up from
> whatever directory you are in.
> candidate I
> no
> were
> directory?
>
> The source code you can put in any convenient
> directory. The resulting
> binaries are subject to the configure options. There
> are three ways of
> using PHP and you need to know which you want. Least
> likely is the
> command line one only (CGI). If using apache httpd
> webserver most likely
> is as an apache module (DSO). The third is to
> compile it into Apache
> itself, which would mean compiling apache too. Your
> existing PHP
> configure line will indicate which. If it has
> --with-apxs (or
> --with-apxs2) then it is an apache DSO. The INSTALL
> file in the root PHP
> source directory gives quite a lot of information.
>
> The basic stages of most software is:
> configure - set up options for compilation.
> make - compile, using the configure options.
> make install - put the resulting files int the right
> place. This stage
> you would normally expect to be the root user for.
> or
> make
>
> Save your existing php.ini file. It is probably in
> /etc but again the
> configure options may put it elsewhere. I'm not sure
> but the make
> install may install a new one. You can overwite it
> with the old one
> afterwards if you want to, or just merge the
> contents. I'm not aware of
> any change needed for PHP 5 as opposed to 4. You
> will need to change
> httpd.conf (assuming Apache), the INSTALL file will
> say how.
>
> You are welcome. I should tell you that I have
> compiled PHP 5 here but I
> do not use it (or payflow pro) but PHP 4.x. Also,
> others on this list
> including Chuck will have information that I may not
> be aware of. YMMV.
>
> Regards
>
> Chris
>
>

Chris Hewitt

2004-11-22, 8:56 pm

On Mon, 2004-11-22 at 22:14, Sarah wrote:
> Ok well I just tried to run the configure command in
> no particular directory and these are my results. Any
> ideas?


You need to be in a particular directory, the one with the configure
script in it. From memory this is the top level PHP source code
directory, but you will need to check.

>
> pfpro=/var/www/html/Verisign/verisign/payflowpro/linuxrh9/perl
> sh: line 1: .configure: command not found
>
> --with-pfpro=/var/www/html/Verisign/verisign/payflowpro/linuxrh9/perl
> sh: line 1: ./configure: No such file or directory
>
> The php bin directory is = /usr/bin.
>
> What am I missing with the configure command? I tried
> figuring out commands with cc but I didn't get very
> far.


I'd forget cc/gcc for now. Lets get over the configure command first.
When you have got into the directory the PHP configure script is in, run
it with the dot and slash before it "./configure". The dot simply means
the current directory, so you are specifying that the configure script
is in the current directory. It may seem silly but just doing
"configure" you may get a "file not found" error (as you did when doing
it from the wrong directories). This is because, in unix, the current
directory is usually not on your PATH.
>
> Thanks again for your help, I think I'm close to
> getting this resolved.
> Sarah


You are welcome. Its 10.40pm here in the UK and I'm stopping for the
night. I'll be around in the morning if there is anything else I may
help with.

Regards

Chris
Sarah

2004-11-23, 8:56 am

First off I need to say I hate configuring and
building php when I've only been hired to build php
code but that's my fault. Anyways I finally got the
evil evil payflow pro stuff integrated and well I
abandoned trying to reconfigure php to do it. Also
before I forgot thank you to Chuck and Chris for all
their help. Here's the code I used to reroute around
the pfpro functions:

# Location of the pfpro binary.
$pfpro = "/www2/bin/pfpro";
# Location of the certs
putenv("PFPRO_CERT_PATH=/www2/Verisign.certs");


# The args to call the binary with
$args =
"USER=$vsInfo[1]&VENDOR=$vsInfo[1]&PARTNER=verisign&"
..
"PWD=$vsInfo[2]&" .
"TRXTYPE=S&TENDER=C&" .
"ACCT=$UserInfo[ccnum]&EXPDATE=$ccexpire&" .
"AMT=$UserInfo[amount]&COMMENT1=$comment1";

# Put together the command string
$command = "$pfpro $vsInfo[3] 443 \"$args\" 10";


$result = `$command`;
Chris Hewitt

2004-11-23, 3:56 pm

On Tue, 2004-11-23 at 11:21, Sarah wrote:
> First off I need to say I hate configuring and
> building php when I've only been hired to build php
> code but that's my fault. Anyways I finally got the
> evil evil payflow pro stuff integrated and well I
> abandoned trying to reconfigure php to do it. Also
> before I forgot thank you to Chuck and Chris for all
> their help. Here's the code I used to reroute around
> the pfpro functions:

-------------snip----------------

As long as you have a means of getting it working then I would say that
is about 100% of what you need!

Regards

Chris
Sponsored Links







Also available: Server administration forum archive | Web Design forum archive | Software forum archive | Hardware reviews archive

Copyright 2008 codecomments.com