#---------------------------------------------------------------------------- # build_apache2-mod_python.txt - how to build the apache2-mod_python binaries and create folder and packages # # Creation : 2015-09-05 holbru # Last update: $Id$ # # !!! this is not a script but an step-by-step howto !!! #---------------------------------------------------------------------------- exit 1 ### download the source code from the internet, e.g. # http:// apache2-mod_python # apache2-mod_python-3.5.0.tar.bz2 ### extract file in a temporary location tar -xf apache2-mod_python-3.5.0.tar.bz2 # 2015-09-05 -> apache2-mod_python-3.5.0 # build with rpom Suse # apache2-mod_python-3.5.0-20.4.src.rpm # 2016-03-21 -> apache2-mod_python-3.5.1 # build with rpm # apache2-mod_python-3.5.1-1.4.src.rpm # patch for 'Fatal Python error: PyEval_SaveThread: NULL tstate' # 2016-07-25 -> apache2-mod_python-3.5.1.1 # build with rpm # checkout with svn up latest trunk # apache2-mod_python-3.5.1.1-1.1.src.rpm # 2016-08-03 -> apache2-mod_python-3.5.1.1 # rebuild with rpm and apache2-2.4.23 # checkout with svn up latest trunk # apache2-mod_python-3.5.1.1-1.1.src.rpm # hbfl # 2018-12-18 -> apache2-mod_python-3.5.1.1 # rebuild with rpm # apache2-mod_python-3.5.1.1-3.1.src.rpm # apache2-mod_python-python3-3.5.1.1-3.1.src.rpm # with python3 relink for python3 required # ln -s libpython3.6m.so.1.0 libpython3.so # hbfl # 2020-02-09 -> apache2-mod_python-3.5.0.3 # rebuild with rpm # apache2-mod_python-3.5.0.3-3.1.src.rpm # apache2-mod_python-python3-3.5.0.3-3.1.src.rpm # svn up # ld problem in configure.in # correct -lpython{2.7|3.6m} setting in src/Makefile # https://github.com/grisha/mod_python/issues/85 # https://github.com/grisha/mod_python/issues/81 # hbfl # 2020-05-21 -> apache2-mod_python-3.5.0.3 # rebuild with rpm # apache2-mod_python-3.5.0.3-3.3.src.rpm # apache2-mod_python-python3-3.5.0.3-3.3.src.rpm # ld problem in configure.in # correct -lpython{2.7|3.8} setting in src/Makefile # hbfl # 2021-03-10 -> apache2-mod_python-3.5.0.3 # rebuild with rpm for python3-3.8.8 # svn co from https://github.com/grisha/mod_python # apache2-mod_python-python3-3.5.0.3-4.3.src.rpm # ld problem in configure.in # correct -lpython3.8 setting in src/Makefile # hbfl # 2021-09-06 -> apache2-mod_python-3.5.0.5 # rebuild with rpm # svn up in python-folder from https://github.com/grisha/mod_python # apache2-mod_python-3.5.0.5-1.2.7.src.rpm -> py-2.7.18-7.1 # apache2-mod_python-python3-3.5.0.5-3.8.11.src.rpm -> py-3.8.11 # ld problem in configure.in # correct -lpython3.8 setting in src/Makefile # hbfl # 2022-05-09 -> mod_python-3.5.0.6 # rebuild with rpm # svn up in python-folder from https://github.com/grisha/mod_python # apache2-mod_python-python27-3.5.0.6-2.7.18.src.rpm -> py-2.7.18-20.1 # apache2-mod_python-python38-3.5.0.6-3.8.13.src.rpm -> py-3.8.13 # apache2-mod_python-python310-3.5.0.6-3.10.4.src.rpm -> py-3.10.4 # ld problem in configure.in # correct -lpython3.8 setting in src/Makefile # detect PyVersion in configure.in gefixt # hbfl # 2023-07-18 -> mod_python-3.5.0.7 # rebuild with rpm # svn up in python-folder from https://github.com/grisha/mod_python # apache2-mod_python-python310-3.5.0.7-3.10.12.src.rpm -> py-3.10.12 # ld problem in configure.in # correct -lpython3.10 setting in src/Makefile # set to sitearch in specfile cd apache2-mod_python-3.5.0 ### build export CFLAGS='-O2 -march=i486' export CXXFLAGS="${CFLAGS}" ./configure \ --prefix=/usr \ --build=i486-pc-linux-gnu \ --host=i486-pc-linux-gnu make make check make DESTDIR=/public/apache2-mod_python install # strip files/binarys for filename in `find /public/apache2-mod_python/usr/{bin/*,lib/*.so.*} -type f` do echo $filename strip -R .note -R .comment "$filename" done # copy files cp *** /lib/apache2-mod_python/bin_**_apache2-mod_python_3_5_0/*** #---------------------------------------------------------------------------- create folder Um die Folder im Hauptverszeichnis zu erstellen gibt es das Script 'apache2-mod_python-folder.sh' unter apache2-mod_python/_ADMIN/ mit apache2-mod_python-folder.sh -v 3.5.0 -w create wird die folder Struktur fuer die lib Version 3.5.0 erstellt nun koennen die files aus dem compilat eingefuegt werden. mit apache2-mod_python-folder.sh -v 3.5.0 -w add wird ein svn add auf die erzeugten Folder durchgefuehrt. mit apache2-mod_python-folder.sh -v 3.5.0 -w list wird fuer jeden Folder die files-list.txt erzeugt, add muss zwingend vorher ausgefuehrt worden sein mit apache2-mod_python-folder.sh -v 3.5.0 -w ci erfolgt der commit der erzeugten Folder In den eis und eis_dev Foldern muessen keine Anpassungen vorgenommen werden. Diese Anpassungen erfolgen beim packen der packages durch mktarball.sh mit den _do_ Scripten unter _ADMIN automatisch. In den Pack-Scripten unter _ADMIN muss dann noch die Pfadangabe geaendert werden, auf den soeben erzeugten Pfad und ein commit ausgefuehrt werden. Nach dem checkout auf eisler koennen nun die packages erzeugt werden. die wichtigsten Parameter fuer mktarball.sh sind dann -setdate now -setversion ${version} mktarball.sh - home -setdate now -setversion [version angeben] apache2-mod_python apache2-mod_python-dev duch die Angabe von -home werden die packages in die Folder Struktur /home/user/public_html/packages/ kopiert und koennen von da direkt auf Pack-Eis geladen werden. wichtig ist noch, dass unbedingt die 'lib' Version zuerst gebaut werden muss, da fuer die 'dev' Version Informationen aus der 'lib' Info Datei gelesen werden.