Skip to content

Commit a189aaa

Browse files
authored
Merge pull request #2792 from signalwire/python
[mod_python] Remove from tree
2 parents a57c895 + 3a53566 commit a189aaa

38 files changed

+11
-20270
lines changed

.gitignore

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,6 @@ Release/
154154
/src/mod/formats/mod_shell_stream/Makefile
155155
/src/mod/languages/mod_lua/mod_lua_wrap.cpp.orig
156156
/src/mod/languages/mod_perl/mod_perl_wrap.cpp.orig
157-
/src/mod/languages/mod_python/mod_python_wrap.cpp.orig
158157
/src/mod/languages/mod_python3/mod_python_wrap.cpp.orig
159158
/src/mod/say/mod_say_de/Makefile
160159
/src/mod/say/mod_say_es/Makefile

Makefile.am

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -706,7 +706,7 @@ pristine:
706706
git clean -fdx
707707
git reset --hard
708708

709-
update-clean: clean python-reconf python3-reconf
709+
update-clean: clean python3-reconf
710710
cd libs/esl && $(MAKE) clean
711711
cd libs/srtp && $(MAKE) clean
712712

@@ -719,10 +719,6 @@ sndfile-reconf:
719719
cd libs/libsndfile && ./config.status --recheck
720720
cd libs/libsndfile && ./config.status
721721

722-
python-reconf:
723-
rm -f src/mod/languages/mod_python/Makefile
724-
./config.status
725-
726722
python3-reconf:
727723
rm -f src/mod/languages/mod_python3/Makefile
728724
./config.status

build/Makefile.centos6

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,8 @@
66
# in that same directory.
77
#
88
#
9-
RPMS=git gcc-c++ autoconf automake libtool wget python ncurses-devel zlib-devel libjpeg-devel openssl-devel e2fsprogs-devel sqlite-devel libcurl-devel pcre-devel speex-devel ldns-devel libedit-devel
10-
DEBS=git build-essential automake autoconf 'libtool-bin|libtool' wget python uuid-dev zlib1g-dev 'libjpeg8-dev|libjpeg62-turbo-dev' libncurses5-dev libssl-dev libpcre3-dev libcurl4-openssl-dev libldns-dev libedit-dev libspeexdsp-dev libspeexdsp-dev libsqlite3-dev perl libgdbm-dev libdb-dev bison libvlc-dev pkg-config
9+
RPMS=git gcc-c++ autoconf automake libtool wget ncurses-devel zlib-devel libjpeg-devel openssl-devel e2fsprogs-devel sqlite-devel libcurl-devel pcre-devel speex-devel ldns-devel libedit-devel
10+
DEBS=git build-essential automake autoconf 'libtool-bin|libtool' wget uuid-dev zlib1g-dev 'libjpeg8-dev|libjpeg62-turbo-dev' libncurses5-dev libssl-dev libpcre3-dev libcurl4-openssl-dev libldns-dev libedit-dev libspeexdsp-dev libspeexdsp-dev libsqlite3-dev perl libgdbm-dev libdb-dev bison libvlc-dev pkg-config
1111

1212
freeswitch: deps has-git freeswitch.git/Makefile
1313
cd freeswitch.git && make

build/modules.conf.in

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,6 @@ formats/mod_tone_stream
103103
languages/mod_lua
104104
#languages/mod_managed
105105
#languages/mod_perl
106-
#languages/mod_python
107106
#languages/mod_python3
108107
#languages/mod_v8
109108
loggers/mod_console

build/swigall.sh

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,6 @@ make swigclean
88
make mod_perl_wrap.cpp
99
cd ../../../..
1010

11-
cd src/mod/languages/mod_python
12-
make swigclean
13-
make mod_python_wrap.cpp
14-
cd ../../../..
15-
1611
cd src/mod/languages/mod_python3
1712
make swigclean
1813
make mod_python_wrap.cpp

conf/insideout/autoload_configs/modules.conf.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@
7373
<!-- Languages -->
7474
<load module="mod_v8"/>
7575
<!-- <load module="mod_perl"/> -->
76-
<!-- <load module="mod_python"/> -->
7776
<!-- <load module="mod_python3"/> -->
7877
<!-- <load module="mod_java"/> -->
7978
<load module="mod_lua"/>

conf/vanilla/autoload_configs/modules.conf.xml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,6 @@
105105
<!-- Languages -->
106106
<!-- <load module="mod_v8"/> -->
107107
<!-- <load module="mod_perl"/> -->
108-
<!-- <load module="mod_python"/> -->
109108
<!-- <load module="mod_python3"/> -->
110109
<!-- <load module="mod_java"/> -->
111110
<load module="mod_lua"/>

configure.ac

Lines changed: 0 additions & 122 deletions
Original file line numberDiff line numberDiff line change
@@ -1732,127 +1732,6 @@ if test "x$ac_cv_have_php" != "xno" -a "x$ac_cv_have_php_config" != "xno"; then
17321732
AC_SUBST(PHP_CFLAGS)
17331733
fi
17341734

1735-
#
1736-
# Python checks for mod_python (scroll down to see python3 checks for mod_python3)
1737-
#
1738-
AC_ARG_WITH(
1739-
[python],
1740-
[AS_HELP_STRING([--with-python], [Use system provided version of python (default: try)])],
1741-
[with_python="$withval"],
1742-
[with_python="try"]
1743-
)
1744-
1745-
if test "$with_python" != "no"
1746-
then
1747-
save_CFLAGS="$CFLAGS"
1748-
save_LIBS="$LIBS"
1749-
1750-
if test "$with_python" != "yes" -a "$with_python" != "try" ; then
1751-
AC_MSG_CHECKING([for python])
1752-
if test ! -x "$with_python" ; then
1753-
AC_MSG_ERROR([Specified python does not exist or is not executable: $with_python])
1754-
fi
1755-
AC_MSG_RESULT([$with_python])
1756-
AC_SUBST([PYTHON], ["$with_python"])
1757-
else
1758-
AC_PATH_PROG([PYTHON], ["python"], ["no"], ["$PATH:/usr/bin:/usr/local/bin"])
1759-
fi
1760-
1761-
if test "$PYTHON" != "no" ; then
1762-
AC_MSG_CHECKING([python version])
1763-
PYTHON_VER="`$PYTHON -V 2>&1 | cut -d' ' -f2`"
1764-
1765-
if test -z "$PYTHON_VER" ; then
1766-
AC_MSG_ERROR([Unable to detect python version])
1767-
fi
1768-
AC_MSG_RESULT([$PYTHON_VER])
1769-
1770-
AC_MSG_CHECKING([for python distutils])
1771-
python_result="`$PYTHON -c 'import distutils;' 2>&1`"
1772-
if test -z "$python_result" ; then
1773-
python_has_distutils="yes"
1774-
else
1775-
python_has_distutils="no"
1776-
fi
1777-
AC_MSG_RESULT([$python_has_distutils])
1778-
1779-
if test "$python_has_distutils" != "no" ; then
1780-
AC_MSG_CHECKING([location of site-packages])
1781-
1782-
PYTHON_SITE_DIR="`$PYTHON -c 'from distutils import sysconfig; print(sysconfig.get_python_lib(0));'`"
1783-
1784-
if test -z "$PYTHON_SITE_DIR" ; then
1785-
AC_MSG_ERROR([Unable to detect python site-packages path])
1786-
elif test ! -d "$PYTHON_SITE_DIR" ; then
1787-
AC_MSG_ERROR([Path $PYTHON_SITE_DIR returned by python does not exist!])
1788-
fi
1789-
AC_MSG_RESULT([$PYTHON_SITE_DIR])
1790-
AC_SUBST([PYTHON_SITE_DIR], [$PYTHON_SITE_DIR])
1791-
1792-
#
1793-
# python distutils found, get settings from python directly
1794-
#
1795-
PYTHON_CFLAGS="`$PYTHON -c 'from distutils import sysconfig; flags = [[\"-I\" + sysconfig.get_python_inc(0), \"-I\" + sysconfig.get_python_inc(1), \" \".join(sysconfig.get_config_var(\"CFLAGS\").split())]]; print(\" \".join(flags));' | sed -e 's/-arch i386//g;s/-arch x86_64//g'`"
1796-
PYTHON_LDFLAGS="`$PYTHON -c 'from distutils import sysconfig; libs = sysconfig.get_config_var(\"LIBS\").split() + sysconfig.get_config_var(\"SYSLIBS\").split(); libs.append(\"-lpython\"+sysconfig.get_config_var(\"VERSION\")); print(\" \".join(libs));'`"
1797-
PYTHON_LIB="`$PYTHON -c 'from distutils import sysconfig; print(\"python\" + sysconfig.get_config_var(\"VERSION\"));'`"
1798-
PYTHON_LIBDIR="`$PYTHON -c 'from distutils import sysconfig; print(sysconfig.get_config_var(\"LIBDIR\"));'`"
1799-
1800-
# handle python being installed into /usr/local
1801-
AC_MSG_CHECKING([python libdir])
1802-
if test -z "`echo $PYTHON_LIBDIR | grep "/usr/lib"`" ; then
1803-
PYTHON_LDFLAGS="-L$PYTHON_LIBDIR $PYTHON_LDFLAGS"
1804-
LIBS="-L$PYTHON_LIBDIR $LIBS"
1805-
fi
1806-
AC_MSG_RESULT([$PYTHON_LIBDIR])
1807-
1808-
# check libpython
1809-
AC_CHECK_LIB([$PYTHON_LIB], [main], [has_libpython="yes"], [has_libpython="no"])
1810-
1811-
if test "$has_libpython" = "no" ; then
1812-
AS_IF([test "$with_python" = "try"],
1813-
[AC_MSG_WARN([$PYTHON_LIB is unusable])],
1814-
[AC_MSG_ERROR([$PYTHON_LIB is unusable])]
1815-
)
1816-
fi
1817-
1818-
# check whether system libpython is usable and has threads support
1819-
CFLAGS="$PYTHON_CFLAGS"
1820-
LIBS="$PYTHON_LDFLAGS"
1821-
AC_CHECK_FUNC([PyThread_init_thread], [python_has_threads="yes"], [python_has_threads="no"])
1822-
1823-
if test "$python_has_threads" = "no"; then
1824-
AS_IF([test "$with_python" = "try"],
1825-
[AC_MSG_WARN([Your python lacks threads support, can not build mod_python])],
1826-
[AC_MSG_ERROR([Your python lacks threads support, can not build mod_python])]
1827-
)
1828-
else
1829-
AC_MSG_NOTICE([Your python seems OK, do not forget to enable mod_python in modules.conf])
1830-
AC_SUBST([PYTHON_CFLAGS], [$PYTHON_CFLAGS])
1831-
AC_SUBST([PYTHON_LDFLAGS], [$PYTHON_LDFLAGS])
1832-
fi
1833-
else
1834-
AS_IF([test "$with_python" = "try"],
1835-
[AC_MSG_WARN([Could not find or use python distutils module: $python_result])],
1836-
[AC_MSG_ERROR([Could not find or use python distutils module: $python_result])]
1837-
)
1838-
fi
1839-
1840-
LIBS="$save_LIBS"
1841-
CFLAGS="$save_CFLAGS"
1842-
1843-
unset python_has_threads
1844-
unset python_has_distutils
1845-
unset python_result
1846-
else
1847-
AS_IF([test "$with_python" = "try"],
1848-
[AC_MSG_WARN([Could not find python, mod_python will not build, use --with-python to specify the location])],
1849-
[AC_MSG_ERROR([Could not find python, use --with-python to specify the location])]
1850-
)
1851-
fi
1852-
else
1853-
AC_MSG_WARN([python support disabled, building mod_python will fail!])
1854-
fi
1855-
18561735
#
18571736
# Python3 checks for mod_python3
18581737
#
@@ -2196,7 +2075,6 @@ AC_CONFIG_FILES([Makefile
21962075
src/mod/languages/mod_lua/Makefile
21972076
src/mod/languages/mod_managed/Makefile
21982077
src/mod/languages/mod_perl/Makefile
2199-
src/mod/languages/mod_python/Makefile
22002078
src/mod/languages/mod_python3/Makefile
22012079
src/mod/languages/mod_v8/Makefile
22022080
src/mod/languages/mod_basic/Makefile

debian/bootstrap.sh

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ avoid_mods_jessie=(
6363
directories/mod_ldap
6464
)
6565
avoid_mods_bookworm=(
66-
languages/mod_python
6766
)
6867
avoid_mods_wheezy=(
6968
event_handlers/mod_amqp
@@ -314,7 +313,7 @@ Build-Depends:
314313
# configure options
315314
libssl1.0-dev | libssl-dev, unixodbc-dev, libpq-dev,
316315
libncurses5-dev, libjpeg62-turbo-dev | libjpeg-turbo8-dev | libjpeg62-dev | libjpeg8-dev,
317-
python-dev | python-dev-is-python2 | python-dev-is-python3, python3-dev, python-all-dev | python3-all-dev, python-support (>= 0.90) | dh-python, erlang-dev, libtpl-dev (>= 1.5),
316+
python-dev-is-python3, python3-dev, python3-all-dev, dh-python, erlang-dev, libtpl-dev (>= 1.5),
318317
# documentation
319318
doxygen,
320319
# for APR (not essential for build)

debian/control-modules

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -537,11 +537,6 @@ Build-Depends-Buster: libperl-dev, libgdbm-compat-dev
537537
Build-Depends-Bullseye: libperl-dev, libgdbm-compat-dev
538538
Build-Depends-Bookworm: libperl-dev, libgdbm-compat-dev
539539

540-
Module: languages/mod_python
541-
Description: mod_python
542-
Adds mod_python.
543-
Build-Depends: python-dev | python-dev-is-python2
544-
545540
Module: languages/mod_python3
546541
Description: mod_python3
547542
Adds mod_python3.

0 commit comments

Comments
 (0)