[mod_python] mod_python on OpenBSD

edgar mortiz pfunix at gmail.com
Wed Sep 13 22:06:46 EDT 2006


Graham,

   I'm installing mod_python as root. I redid everything on the mod_python part

./configure --with-apxs=/usr/chroot/httpd/bin/apxs
--with-python=/usr/local/bin/python2.4
--with-flex=/usr/chroot/flex/bin/flex

gmake

# gmake install_dso
gmake[1]: Entering directory `/usr/chroot/src/mod_python-3.2.10/src'

Compiling for DSO.

/usr/chroot/httpd/bin/apxs
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4 -c
mod_python.c _apachemodule.c requestobject.c tableobject.c util.c
serverobject.c connobject.c filterobject.c hlist.c hlistobject.c
-L/usr/local/lib/python2.4/config  -Wl,--export-dynamic      -lm
-lpython2.4    -lutil   -lm
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
mod_python.lo mod_python.c && touch mod_python.slo
mod_python.c: In function `python_cleanup':
mod_python.c:313: warning: passing arg 1 of `free' discards qualifiers
from pointer target type
mod_python.c: In function `init_mutexes':
mod_python.c:427: warning: assignment discards qualifiers from pointer
target type
mod_python.c:458: warning: assignment discards qualifiers from pointer
target type
mod_python.c: In function `reinit_mutexes':
mod_python.c:540: warning: assignment discards qualifiers from pointer
target type
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
_apachemodule.lo _apachemodule.c && touch _apachemodule.slo
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
requestobject.lo requestobject.c && touch requestobject.slo
requestobject.c: In function `req_get_options':
requestobject.c:426: warning: initialization discards qualifiers from
pointer target type
requestobject.c:427: warning: initialization from incompatible pointer type
requestobject.c: In function `getmakeobj':
requestobject.c:1447: warning: assignment from incompatible pointer type
requestobject.c:1454: warning: assignment from incompatible pointer type
requestobject.c: In function `request_tp_clear':
requestobject.c:1569: warning: assignment from incompatible pointer type
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
tableobject.lo tableobject.c && touch tableobject.slo
tableobject.c:1057: warning: initialization from incompatible pointer type
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
util.lo util.c && touch util.slo
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
serverobject.lo serverobject.c && touch serverobject.slo
serverobject.c:351: warning: initialization from incompatible pointer type
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
connobject.lo connobject.c && touch connobject.slo
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
filterobject.lo filterobject.c && touch filterobject.slo
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
hlist.lo hlist.c && touch hlist.slo
/usr/chroot/httpd/build/libtool --silent --mode=compile gcc
-prefer-pic   -D_POSIX_THREADS -g -O2 -pthread
-I/usr/chroot/httpd/include  -I/usr/chroot/httpd/include
-I/usr/chroot/httpd/include
-I/usr/chroot/src/mod_python-3.2.10/src/include
-I/usr/chroot/httpd/include -I/usr/local/include/python2.4  -c -o
hlistobject.lo hlistobject.c && touch hlistobject.slo
/usr/chroot/httpd/build/libtool --silent --mode=link gcc -o
mod_python.la  -rpath /usr/chroot/httpd/modules -module -avoid-version
   hlistobject.lo hlist.lo filterobject.lo connobject.lo
serverobject.lo util.lo tableobject.lo requestobject.lo
_apachemodule.lo mod_python.lo -L/usr/local/lib/python2.4/config
-Wl,--export-dynamic -lm -lpython2.4 -lutil -lm

*** Warning: linker path does not have real file for library -lpython2.4.
*** I have the capability to make that library automatically link in when
*** you link to this library.  But I can only do this if you have a
*** shared version of the library, which you do not appear to have
*** because I did check the linker path looking for a file starting
*** with libpython2.4 and none of the candidates passed a file format test
*** using a regex pattern. Last file checked:
/usr/local/lib/python2.4/config/libpython2.4.a

*** Warning: libtool could not satisfy all declared inter-library
*** dependencies of module mod_python.  Therefore, libtool will create
*** a static module, that should work as long as the dlopening
*** application is linked with the -dlopen flag.
gmake[1]: Leaving directory `/usr/chroot/src/mod_python-3.2.10/src'
gmake[1]: Entering directory `/usr/chroot/src/mod_python-3.2.10/dist'
gmake[2]: Entering directory `/usr/chroot/src/mod_python-3.2.10/src'
gmake[2]: `psp_parser.c' is up to date.
gmake[2]: Leaving directory `/usr/chroot/src/mod_python-3.2.10/src'
/usr/local/bin/python2.4 setup.py build
running build
running build_py
running build_ext
gmake[1]: Leaving directory `/usr/chroot/src/mod_python-3.2.10/dist'

Now su and make install
  (or, if you only want to perform a partial install,
   you can use make install_dso and make install_py_lib)


Performing DSO installation.

/usr/bin/install -c -d /usr/chroot/httpd/modules
/usr/bin/install -c src/mod_python.so /usr/chroot/httpd/modules
install: src/mod_python.so: No such file or directory
gmake: *** [install_dso] Error 71
#

it breaks when i do install_dso

-eD

On 9/12/06, Graham Dumpleton <grahamd at dscpl.com.au> wrote:
> Run:
>
>    make install_dso
>
> Copy and paste the output here so we can see where it is trying to
> install
> it. Also tell us where it is meant to be going.
>
> Does the user you are running the install as, have permission to install
> in that location.
>
> Graham
>
> On 13/09/2006, at 2:40 PM, edgar mortiz wrote:
>
> > it seems that whenever i do a make install no files are getting
> > coppied to the modules folder on  apache.
> >
> > this is a bit frustrating. is ther any way to build python via static
> > instead of the regular DSO (even if it says on the docs that DSO is
> > the only think that is available)
> >
> >
> > any help will be greatly appreciated.
> >
> > -eD
> >
> > On 9/12/06, edgar mortiz <pfunix at gmail.com> wrote:
> >> sorry about the confusion the --with-apxs=/web/httpd the first time i
> >> did it (this was when building mod_python breaks during 'make
> >> install')
> >>
> >> the new one i did is on /httpd so my apxs would be in /httpd/bin/apxs
> >>
> >> -ed
> >>
> >> On 9/12/06, Jorey Bump <list at joreybump.com> wrote:
> >> > edgar mortiz wrote:
> >> >
> >> > > # bin/apachectl start
> >> > > Syntax error on line 233 of /httpd/conf/httpd.conf:
> >> >
> >> > This path:
> >> >
> >> > > Cannot load /httpd/modules/mod_python.so into server: Can't
> >> open file
> >> >
> >> > Doesn't match this path:
> >> >
> >> > >> > ./configure --with-apxs=/web/httpd/bin/apxs
> >> >
> >> > Is there a reason for this? I don't know how OpenBSD installs
> >> apache.
> >> > Do you have both 1.3.x and 2.0.x installed?
> >> >
> >>
> > _______________________________________________
> > Mod_python mailing list
> > Mod_python at modpython.org
> > http://mailman.modpython.org/mailman/listinfo/mod_python
>
>


More information about the Mod_python mailing list