]> git.pld-linux.org Git - packages/beecrypt.git/blob - beecrypt-python.patch
- release 4
[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,61 @@
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.4)
57 +AC_TRY_RUN([
58 +#include <python2.4/Python.h>
59 +main() {
60 +  exit(strncmp("2.4", 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.4"
66 +  else
67 +    AC_MSG_CHECKING(for python 2.2)
68 +    AC_TRY_RUN([
69 +#include <python2.2/Python.h>
70 +main() {
71 +  exit(strncmp("2.2", PY_VERSION, 3));
72 +} ],
73 +      withval=yes, withval=no, withval=yes)
74 +      AC_MSG_RESULT($withval)
75 +      if test $withval = yes ; then
76 +        WITH_PYTHON_VERSION="2.2"
77 +      else
78 +
79 +        AC_MSG_CHECKING(for python 1.5.2)
80 +        AC_TRY_RUN([
81 +#include <python1.5/Python.h>
82 +main() {
83 +  exit(strcmp("1.5.2", PY_VERSION));
84 +} ],
85 +        withval=yes, withval=no, withval=yes)
86 +        AC_MSG_RESULT($withval)
87 +        if test $withval = yes ; then
88 +          WITH_PYTHON_VERSION="1.5"
89 +        else
90 +          AC_MSG_CHECKING(for python 2.3)
91 +        AC_TRY_RUN([
92 +       #include <python2.3/Python.h>
93 +       main() {
94 +        exit(strncmp("2.3", PY_VERSION, 3));
95 +        } ],
96 +           withval=yes, withval=no, withval=yes)
97 +           AC_MSG_RESULT($withval)
98 +           if test $withval = yes ; then
99 +           WITH_PYTHON_VERSION="2.3"
100 +         fi
101 +       fi
102 +    fi
103 +  fi
104 +fi
105 +
106 +
107 +AC_SUBST(WITH_PYTHON_VERSION)
108 +
109  # Checks for entropy sources.
110  AS_MESSAGE(checking for specific entropy devices...)
111  case $target_os in
This page took 0.029624 seconds and 3 git commands to generate.