123456789101112131415161718192021222324252627282930313233343536373839404142434445464748 |
- /*
- * Copyright (C) 2019 Weber Yann
- *
- * This file is part of PyFCGI.
- *
- * PyFCGI is free software: you can redistribute it and/or modify
- * it under the terms of the GNU Affero General Public License as published by
- * the Free Software Foundation, either version 3 of the License, or
- * any later version.
- *
- * PyFCGI is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
- * GNU Affero General Public License for more details.
- *
- * You should have received a copy of the GNU Affero General Public License
- * along with PyFCGI. If not, see <http://www.gnu.org/licenses/>.
- */
- #ifndef _PYUTILS__H__
- #define _PYUTILS__H__
-
- #include "config.h"
-
- #include <fcgiapp.h>
- #include <fcgi_stdio.h> /* fcgi library; put it first*/
-
- #define PY_SSIZE_T_CLEAN
- #include <Python.h>
-
- #include "logger.h"
-
- /**@brief Call Py_Initialize & update_python_path
- */
- void pyinit();
-
- /**@brief Add . to the embed pythonpath
- */
- void update_python_path();
-
- /**@brief Import & return the python entrypoint callable
- * from PyFCGI_conf.py_entrymod & PyFCGI_conf.py_entryfun
- */
- PyObject* import_entrypoint();
-
- void log_expt(int priority);
-
- #endif
|