Link to home
Start Free TrialLog in
Avatar of freburg
freburg

asked on

HP-UX 10.20 and PHP question

hi

i am trying to setup php on my hp-ux 10.20 machine.
I found depot software for apache and mysql. All i need is to install php and to configure the httpd.conf file.

I found an unix verions of php. When i run the configure file however i get the error ^M not found for about 500 lines. then on line 1000 it says syntax error and it stops running the script.

what could cause this?

Regard Freburg
ASKER CERTIFIED SOLUTION
Avatar of yuzh
yuzh

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of freburg
freburg

ASKER

Ok,...it seems to work

i will award the point when i get my php up and running :-D
Avatar of freburg

ASKER

got some other prob now

loading cache ./config.cache
checking for Cygwin environment... no
checking for mingw32 environment... no
checking host system type... hppa1.1-hp-hpux10.20
checking for a BSD compatible install... /tmp/php/install-sh -c
checking whether build environment is sane... yes
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets ${MAKE}... yes
checking whether to enable maintainer-specific portions of Makefiles... no
script interpreter "/sbin/sh" not found
/tmp/php/configure[1643]: /tmp/php/build/shtool:  not found.
script interpreter "/sbin/sh" not found
/tmp/php/configure[1644]: /tmp/php/build/shtool:  not found.
script interpreter "/sbin/sh" not found
/tmp/php/configure[1653]: /tmp/php/build/shtool:  not found.
checking for gcc... no
checking for cc... cc
checking whether the C compiler (cc  ) works... yes
checking whether the C compiler (cc  ) is a cross-compiler... no
checking whether we are using GNU C... no
checking whether cc accepts -g... no
checking for style of include used by make... GNU
checking dependency style of cc... none
checking whether cc understands -c and -o together... yes
checking how to run the C preprocessor... cc -E
checking for AIX... no
checking for cc option to accept ANSI C... no
checking whether compiler supports -R... no
checking whether compiler supports -Wl,-rpath,... no
checking for ranlib... ranlib
checking whether ln -s works... yes
checking for gawk... (cached) awk
checking for bison... no
checking for byacc... no
configure: warning: You will need bison if you want to regenerate the PHP parser
s.
checking for flex... lex
checking for yywrap in -ll... yes
checking lex output file root... /tmp/php/configure[2516]: lex:  not found.
configure: error: cannot find output from lex; giving up
#

I know i have bison installed (downloaded a depot and installed it with SAM)
Avatar of freburg

ASKER

i checked and /sbin/sh and the file  /tmp/php/build/shtool are both in place
To make the life easy, you should download the following GUN tools before compiling the php. (they are very usefull)

gcc  (it is very easy to use gcc to compile php)
make, flex, bison, autoconf, automake, perl, gzip, binutils, zlib, tar (GUN)
m4 (if you don't have it installed)

You can get them from the following site (FREE):

http://hpux.cict.fr/

just do a search for the name the download the one for your
OS version. (eg HP-UX 10.20/HP-UX 11.x etc)

if some of the about tools are install at /usr/local, make sure that you do: (for sh/ksh/bash)
PATH=/usr/local/bin:$PATH
export PATH
and put you gcc lib in LD_LIBRARY_PATH as well

for csh/tcsh use set and setenv to set it up.

Good luck
==============
yuzh




BTW, is there any reason you're using 10.20 instead of 11.00 or (even better) 11.11 (aka 11i)? Support for 10.20 is going away in a year, and it's a royal pain to get anything from the net to work on it.
Looking on the "./configure" output...

Seems that not only Makefile is in DOS format, but also
some scripts that are run by "/sbin/sh" and "/tmp/php/build/shtool".

Try to find them :-)

Does it make sence to re-get the sources from a place
that gives it in a binary mode (with UNIX newlines, not the DOS ones) ?
A quick look at the configure output suggests that /sbin/sh might be a symbolic link or even a script that is supposed to call the regular sh (usually /bin/sh) check that it's not a dead symbolic link. In addition to bison you need lex or flex. configure seems to think you have lex, but cant find it later, make sure lex or flex are in your path, so be sure you could consider putting a copy or symbolic link to flex in /usr/bin
Hi casevanrij,

    Welcome to EE, it is a command practice to provide comments unless you know your answer is the only answer and is 300% correct and is what the questioner is looking for and will fix their problem. It will not cause the question to be locked, more exposure to other experts so that the problem get fixed quicker.  

    Please remember NEVER post a comment as an answer, unless you are 300% sure, what you post is the ONLY solution to the problem.

    Regards
        yuzh


   
No comment has been added lately, so it's time to clean up this Topic Area.
I will leave a recommendation for this question in the Cleanup topic area as follows:

- Answered by yuzh

Please leave any comments here within the next 7 days

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

tfewster
Cleanup Volunteer
per recommendation

SpideyMod
Community Support Moderator @Experts Exchange