Please login or register. August 20, 2017, 09:47:09 AM

Author Topic: Create Apache Binary Distribution for AIX 6.1  (Read 17477 times)

0 Members and 1 Guest are viewing this topic.

halawia

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Create Apache Binary Distribution for AIX 6.1
« on: October 27, 2009, 03:38:05 PM »
I succeeded to copmile apache 2.2.14 with mod_jk on aix 6.1.

Now, Has anyone created a binary distribution of apache 2.2.14 for aix 6.1 ??

If yes can you tell me what are the steps to follow in order to proceed?

Thank you

Michael

  • Administrator
  • Hero Member
  • *****
  • Posts: 1041
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #1 on: October 27, 2009, 05:41:17 PM »
I have been working on creating an installp package of apache and need to test it. If you want to volunteer to test it for a download and install I will gladly send you a link to download it from.

I would also gladly accept assistance in creating a new repository forum - so that peolpe could browse/search for packages as more become available.
And also, a "accept license, that provided as is, stc, disclaimer before the download starts".

To compile it yourself, the steps are fairly straight forward.

Download apache from apache.org.
Patch the config.guess file from autoconf2.264 or later (2.63 might be up to date, but I used 2.64)

michael@x054:[/data/prj/httpd-2.2.14]find ../auto* -ls | grep guess
202460   27 -rwxr-xr-x  1 cpan      101         26702 Jan  5  1999 ../autoconf-2.13/config.guess
140674   44 -rwxr-xr-x  1 michael   www          44914 Aug  7  2008 ../autoconf-2.63/build-aux/config.guess
140423    2 -rw-r--r--  1 michael   www           2040 Aug  7  2008 ../autoconf-2.63/man/config.guess.1
140424    1 -rw-r--r--  1 michael   www            938 Jan 15  2001 ../autoconf-2.63/man/config.guess.x
295065   45 -rwx------  1 michael   www          45612 Jul 27 01:45 ../autoconf-2.64/build-aux/config.guess
299083    2 -rw-------  1 michael   www           2030 Jul 27 03:18 ../autoconf-2.64/man/config.guess.1
299084    1 -rw-------  1 michael   www            938 Jan 15  2001 ../autoconf-2.64/man/config.guess.x


michael@x054:[/data/prj/httpd-2.2.14]find . -ls | grep guess
304009   45 -rwx------  1 michael   www          45612 Oct  7 15:04 ./build/config.guess
305783   45 -rwx------  1 michael   www          45612 Oct  7 15:04 ./srclib/apr/build/config.guess
306306   45 -rwx------  1 michael   www          45612 Oct  7 15:04 ./srclib/apr-util/build/config.guess
306817   45 -rwx------  1 michael   www          45612 Oct  7 15:04 ./srclib/apr-util/xml/expat/conftools/config.guess


I have used export CC=xlc and export CC=cc - both seem to work. The rest depends on what modules you want created. I am not using ldap e.g..
./configure --prefix=/usr/local/apache2 \
--enable-module=so \
--enable-module=unique_id \
--enable-module=usertrack \
--enable-module=vhost_alias \
--enable-rewrite=shared \
--enable-speling=shared \
--enable-digest=shared \
--enable-cgi=shared \
--enable-headers=shared \
--enable-info=shared \
--enable-log_forensic=shared \
--enable-proxy=shared \
--enable-proxy-connect=shared \
--enable-proxy-ftp=shared \
--enable-proxy-http=shared \
--enable-proxy-ajp=shared \
--enable-proxy-balancer=shared \
--with-z=/data/prj/zlib-1.2.3


Note: I also have built zlib (in this case still version 1.2.3) and point configure at the sources. Another "improvement" I want to do is use apr and apr-util as separate modules and not use the apr and apr-util included in the apache source tree. I have read that there are some expactations of other packages that also use apr and apr-util - that httpd (apache) is using the same version.

Michael

  • Administrator
  • Hero Member
  • *****
  • Posts: 1041
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #2 on: October 27, 2009, 06:18:46 PM »
The next steps:

after the build is complete you need to run
Quote
make install
but it needs to go to a separate area for packaging.

DISTDIR=/data/prj/build/apache make install

This will perform a normal install - except it is installed not in ${PREFIX}/* but in ${DISTDIR}/$PREFIX/*.

I used the command mkinstallp to make a template:
Package Name: aixt.test
Package VRMF: 1.3.8.0
Update: N
Fileset
  Fileset Name: aixt.test.rte
  Fileset VRMF: 1.3.8.0
  Fileset Description: AIX Tools Test Package
  USRLIBLPPFiles
  EOUSRLIBLPPFiles
  Bosboot required: N
  License agreement acceptance required: N
  Include license files in this package: N
  Requisites:
  USRFiles
/usr/local/bin
/usr/local/bin/testcmd
  EOUSRFiles
  ROOT Part: N
  ROOTFiles
  EOROOTFiles
  Relocatable: N
EOFileset


The main changes are to the LPP name and fileset Name to create a template for apache. For the files I did the following:
cd $DESTDIR
mkdir -p ../.info
find ./usr | sed s/^.// >../.info/apache2.files

The output of this file is what I place between the
  USRFiles
  EOUSRFiles

tags

So I end up with something like:
Package Name: axt.apache2
Package VRMF: 2.14.0.0
Update: N
Fileset
  Fileset Name: axt.apache2.rte
  Fileset VRMF: 2.14.0.0
  Fileset Description: Apache2.2.14 with built APR
  USRLIBLPPFiles
  EOUSRLIBLPPFiles
  Bosboot required: N
  License agreement acceptance required: N
  Include license files in this package: N
  Requisites:
  Upsize: /usr/local 65000;
  USRFiles
        /usr
        /usr/local
        /usr/local/apache2
        /usr/local/apache2/lib
        /usr/local/apache2/lib/pkgconfig
        /usr/local/apache2/lib/pkgconfig/apr-1.pc
        /usr/local/apache2/lib/pkgconfig/apr-util-1.pc
        /usr/local/apache2/lib/libapr-1.so.0
....
    /usr/local/apache2/manual/urlmapping.html.ja.utf8
    /usr/local/apache2/manual/urlmapping.html.ko.euc-kr
    /usr/local/apache2/manual/urlmapping.html.tr.utf8
    EOUSRFiles
ROOT Part: N
ROOTFiles
EOROOTFiles
Relocatable: N
EOFileset


I then use the mkinstallp -d $DESTDIR -f <TEMPLATEFILE> to create an installp file.

halawia

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #3 on: October 28, 2009, 09:22:27 AM »
hello again i made a ./binbuild.sh and i am having a problem with expat 2.0.1 on aix 6.1

this is the following error :

Code: [Select]
xml/apr_xml.c:35:19: error: expat.h: A file or directory in the path name does not exist.
xml/apr_xml.c:66: error: expected specifier-qualifier-list before 'XML_Parser'
xml/apr_xml.c: In function 'cleanup_parser':
xml/apr_xml.c:344: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:345: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c: At top level:
xml/apr_xml.c:364: error: expected ';', ',' or ')' before '*' token
xml/apr_xml.c: In function 'apr_xml_parser_create':
xml/apr_xml.c:381: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:382: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:390: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:391: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:392: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:404: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:404: error: 'default_handler' undeclared (first use in this function)
xml/apr_xml.c:404: error: (Each undeclared identifier is reported only once
xml/apr_xml.c:404: error: for each function it appears in.)
xml/apr_xml.c: In function 'do_parse':
xml/apr_xml.c:414: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:418: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:422: error: 'apr_xml_parser' has no member named 'xp_err'
xml/apr_xml.c:422: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c: In function 'apr_xml_parser_geterror':
xml/apr_xml.c:480: error: 'apr_xml_parser' has no member named 'xp_err'
xml/apr_xml.c:480: error: 'apr_xml_parser' has no member named 'xp_err'
make: 1254-004 The error code from the last command is 1.

Any ideas ? thx

halawia

  • New Member
  • *
  • Posts: 3
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #4 on: October 28, 2009, 06:00:39 PM »
I succeeded to copmile apache 2.2.14 with mod_jk on aix 6.1.

Now, Has anyone created a binary distribution of apache 2.2.14 for aix 6.1 ??

If yes can you tell me what are the steps to follow in order to proceed?

Thank you

well i managed to get over a lot of problems but not this one any one did ?


exec(): 0509-036 Cannot load program ./bindist/bin/httpd because of the following errors:
rtld: 0712-001 Symbol XML_StopParser was referenced
      from module /opt/jonas/httpd-2.2.14/lib/libaprutil-1.so(), but a runtime definition
      of the symbol was not found.
sed: 0602-419 Cannot find or open file bindist/conf/httpd-std.conf.
Creating distribution archive and readme file...


Suggestions and help would be appreciated...thx

Michael

  • Administrator
  • Hero Member
  • *****
  • Posts: 1041
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #5 on: October 28, 2009, 07:54:49 PM »
The problem is it is not finding the libraries via the libpath in the application. To see the libpath compiled use dump -H
michael@x054:[/data/home/michael/prj/httpd-2.2.14]dump -H .libs/httpd

.libs/httpd:

                        ***Loader Section***
                      Loader Header Information
VERSION#         #SYMtableENT     #RELOCent        LENidSTR
0x00000001       0x000002fc       0x000013c8       0x0000008b      

#IMPfilID        OFFidSTR         LENstrTBL        OFFstrTBL
0x00000006       0x00013520       0x000039eb       0x000135ab      


                        ***Import File Strings***
INDEX  PATH                          BASE                MEMBER              
0      /usr/local/apache2/lib:/usr/vac/lib:/usr/lib:/lib                                        
1                                    libaprutil-1.so                        
2                                    libapr-1.so                            
3                                    libpthread.a        shr_xpg5.o          
4                                    libc.a              shr.o              
5                                    librtl.a            shr.o      


To help the configure process you can supply some link flags to the ./configure script, e.g. to compile php I need to help it find the correct libssl and myslq libraries. I do this by using:

# export LDFLAGS='-blibpath:/usr/lib:/usr/local/mysql/lib'
# ./configure


I hope this resolves your current problem.

Almost forgot: you can also export LIBPATH with a correct search path for libraries without recompiling (e.g. to test what your new setting needs to be.)

Michael

  • Administrator
  • Hero Member
  • *****
  • Posts: 1041
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #6 on: October 28, 2009, 08:01:37 PM »
hello again i made a ./binbuild.sh and i am having a problem with expat 2.0.1 on aix 6.1

this is the following error :

Code: [Select]
xml/apr_xml.c:35:19: error: expat.h: A file or directory in the path name does not exist.
xml/apr_xml.c:66: error: expected specifier-qualifier-list before 'XML_Parser'
xml/apr_xml.c: In function 'cleanup_parser':
xml/apr_xml.c:344: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:345: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c: At top level:
xml/apr_xml.c:364: error: expected ';', ',' or ')' before '*' token
xml/apr_xml.c: In function 'apr_xml_parser_create':
xml/apr_xml.c:381: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:382: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:390: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:391: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:392: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:404: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:404: error: 'default_handler' undeclared (first use in this function)
xml/apr_xml.c:404: error: (Each undeclared identifier is reported only once
xml/apr_xml.c:404: error: for each function it appears in.)
xml/apr_xml.c: In function 'do_parse':
xml/apr_xml.c:414: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:418: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c:422: error: 'apr_xml_parser' has no member named 'xp_err'
xml/apr_xml.c:422: error: 'apr_xml_parser' has no member named 'xp'
xml/apr_xml.c: In function 'apr_xml_parser_geterror':
xml/apr_xml.c:480: error: 'apr_xml_parser' has no member named 'xp_err'
xml/apr_xml.c:480: error: 'apr_xml_parser' has no member named 'xp_err'
make: 1254-004 The error code from the last command is 1.

Any ideas ? thx

If I recall correctly, there is a bug, that is fixed in the new sources in which they added a C++ style comment. Just change that comment to a regular C style (not // but /* some comment */ ) and it should compile fine.

John R Peck

  • Administrator
  • Senior Member
  • *****
  • Posts: 134
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #7 on: October 29, 2009, 07:31:17 PM »

I would like to say how much we appreciate Michael's compilation efforts here - this site would not be here otherwise. 

The new section/site with the growing collection makes an excellent resource from a trusted source.

Michael

  • Administrator
  • Hero Member
  • *****
  • Posts: 1041
  • Karma: +0/-0
Re: Create Apache Binary Distribution for AIX 6.1
« Reply #8 on: November 21, 2009, 11:50:17 AM »
Just want to mention - I have an installp file ready for 'testing' at http://dl.aixtools.org/apache2/aixt.apache2.2.14.0.0.bff
If you try it, and there are problems - please let me know so I can make a better one, or figure out how to make it work for you as is.

I will investigate - real soon - what is needed to make it more portable - so that it can be installed in a WPAR e.g..