]> git.pld-linux.org Git - packages/beecrypt.git/blob - beecrypt-python.patch
- BR: python-devel
[packages/beecrypt.git] / beecrypt-python.patch
1 --- beecrypt-3.0.0/python/Makefile.am.orig      2003-06-29 15:10:28.000000000 +0200
2 +++ beecrypt-3.0.0/python/Makefile.am   2003-06-29 15:12:10.000000000 +0200
3 @@ -4,11 +4,11 @@
4  
5  LINT = splint
6  
7 -PYVER= 2.2
8 -
9 +PYVER= @WITH_PYTHON_VERSION@
10
11  SUBDIRS = test
12  
13 -pylibdir = $(shell python -c 'import sys; print sys.path[1]')
14 +pylibdir = $(prefix)/lib/python${PYVER}
15  pyincdir = $(prefix)/include/python${PYVER}
16  
17  EXTRA_DIST = debug-py.c
18 --- beecrypt-3.0.0/python/test/Makefile.am.orig 2003-06-29 15:12:33.000000000 +0200
19 +++ beecrypt-3.0.0/python/test/Makefile.am      2003-06-29 15:13:45.000000000 +0200
20 @@ -2,9 +2,10 @@
21  
22  AUTOMAKE_OPTIONS = 1.4 foreign
23  
24 -PYVER= 2.2
25 +PYVER= @WITH_PYTHON_VERSION@
26  
27 -pylibdir = $(shell python -c 'import sys; print sys.path[1]')
28 +
29 +pylibdir = $(prefix)/lib/python${PYVER}
30  VALGRIND = # valgrind --verbose --leak-check=yes
31  
32  EXTRA_DIST = \
33 --- beecrypt-3.0.0/configure.ac.orig    2003-06-29 15:32:40.000000000 +0200
34 +++ beecrypt-3.0.0/configure.ac 2003-06-29 15:32:47.000000000 +0200
35 @@ -174,13 +174,7 @@
36    fi
37    ],[ac_with_java=no])
38  
39 -AC_ARG_WITH(python,[  --with-python         creates the python bindings code [default=no]],[
40 -  if test "$withval" = no; then
41 -    ac_with_python=no
42 -  else
43 -    ac_with_python=yes
44 -  fi
45 -  ],[ac_with_python=no])
46 +AC_ARG_WITH(python,[  --with-python         creates the python bindings code])
47  
48  # Check for Unix variants
49  AC_AIX
50 @@ -561,6 +555,49 @@
51    AC_DEFINE([JAVAGLUE],1)
52  fi
53  
54 +# CHECK for python
55 +if test $withval = yes ; then
56 +AC_MSG_CHECKING(for python 2.2)
57 +AC_TRY_RUN([
58 +#include <python2.2/Python.h>
59 +main() {
60 +  exit(strncmp("2.2", PY_VERSION, 3));
61 +} ],
62 +  withval=yes, withval=no, withval=yes)
63 +  AC_MSG_RESULT($withval)
64 +  if test $withval = yes ; then
65 +    WITH_PYTHON_VERSION="2.2"
66 +  else
67 +
68 +    AC_MSG_CHECKING(for python 1.5.2)
69 +    AC_TRY_RUN([
70 +#include <python1.5/Python.h>
71 +main() {
72 +  exit(strcmp("1.5.2", PY_VERSION));
73 +} ],
74 +    withval=yes, withval=no, withval=yes)
75 +    AC_MSG_RESULT($withval)
76 +    if test $withval = yes ; then
77 +      WITH_PYTHON_VERSION="1.5"
78 +    else
79 +         AC_MSG_CHECKING(for python 2.3)
80 +    AC_TRY_RUN([
81 +       #include <python2.3/Python.h>
82 +       main() {
83 +        exit(strncmp("2.3", PY_VERSION, 3));
84 +        } ],
85 +       withval=yes, withval=no, withval=yes)
86 +       AC_MSG_RESULT($withval)
87 +       if test $withval = yes ; then
88 +       WITH_PYTHON_VERSION="2.3"
89 +       fi
90 +    fi
91 +  fi
92 +fi
93 +
94 +
95 +AC_SUBST(WITH_PYTHON_VERSION)
96 +
97  # Checks for entropy sources.
98  AS_MESSAGE(checking for specific entropy devices...)
99  case $target_os in
This page took 0.051542 seconds and 3 git commands to generate.