[prev in list] [next in list] [prev in thread] [next in thread] 

List:       openser-devel
Subject:    [sr-dev] git:master:ad91e860: app_python3s: utils - updated too to generate export map code
From:       Daniel-Constantin Mierla <miconda () gmail ! com>
Date:       2022-11-30 17:54:12
Message-ID: E1p0ROC-0007Np-LC () www ! kamailio ! org
[Download RAW message or body]

Module: kamailio
Branch: master
Commit: ad91e860ede6aafcccdf976ad5ff0d4f7aa71fd0
URL: https://github.com/kamailio/kamailio/commit/ad91e860ede6aafcccdf976ad5ff0d4f7aa71fd0


Author: Daniel-Constantin Mierla <miconda@gmail.com>
Committer: Daniel-Constantin Mierla <miconda@gmail.com>
Date: 2022-11-30T16:44:17+01:00

app_python3s: utils - updated too to generate export map code

---

Modified: src/modules/app_python3s/utils/app_python_ctl

---

Diff:  https://github.com/kamailio/kamailio/commit/ad91e860ede6aafcccdf976ad5ff0d4f7aa71fd0.diff
                
Patch: https://github.com/kamailio/kamailio/commit/ad91e860ede6aafcccdf976ad5ff0d4f7aa71fd0.patch


---

diff --git a/src/modules/app_python3s/utils/app_python_ctl \
b/src/modules/app_python3s/utils/app_python_ctl index 7fff1c7f2de..3df49d97448 100755
--- a/src/modules/app_python3s/utils/app_python_ctl
+++ b/src/modules/app_python3s/utils/app_python_ctl
@@ -2,11 +2,11 @@
 
 # generate the .h file
 
-KEMI_MAX_SIZE=1024
+KEMI_MAX_SIZE=1536
 
-cat > ../apy_kemi_export.h <<EOF
+cat > ../apy3s_kemi_export.h <<EOF
 /**
- * Copyright (C) 2016 Daniel-Constantin Mierla (asipto.com)
+ * Copyright (C) 2022 Daniel-Constantin Mierla (asipto.com)
  *
  * This file is part of Kamailio, a free SIP server.
  *
@@ -30,8 +30,8 @@ cat > ../apy_kemi_export.h <<EOF
  * this file is generated - do not edit
  */
 
-#ifndef __APY_KEMI_FLIB_H__
-#define __APY_KEMI_FLIB_H__
+#ifndef __APY3S_KEMI_FLIB_H__
+#define __APY3S_KEMI_FLIB_H__
 
 #include <Python.h>
 #include "../../core/kemi.h"
@@ -51,9 +51,9 @@ EOF
 
 # generate the .c file
 
-cat > ../apy_kemi_export.c <<EOF
+cat > ../apy3s_kemi_export.c <<EOF
 /**
- * Copyright (C) 2016 Daniel-Constantin Mierla (asipto.com)
+ * Copyright (C) 2022 Daniel-Constantin Mierla (asipto.com)
  *
  * This file is part of Kamailio, a free SIP server.
  *
@@ -85,37 +85,37 @@ cat > ../apy_kemi_export.c <<EOF
 
 #include "../../core/dprint.h"
 
-#include "apy_kemi.h"
-#include "apy_kemi_export.h"
+#include "apy3s_kemi.h"
+#include "apy3s_kemi_export.h"
 
 EOF
 
 CEND=${KEMI_MAX_SIZE}
 
 for (( c=0; c<CEND; c++ )); do
-	echo >>../apy_kemi_export.c
-	echo "/**" >>../apy_kemi_export.c
-	echo " *" >>../apy_kemi_export.c
-	echo " */" >>../apy_kemi_export.c
-	echo "static PyObject *sr_apy_kemi_exec_func_${c}(PyObject *self, PyObject *args)" \
                >>../apy_kemi_export.c
-	echo "{" >>../apy_kemi_export.c
-	echo "	return sr_apy_kemi_exec_func(self, args, ${c});" >>../apy_kemi_export.c
-	echo "}" >>../apy_kemi_export.c
+	echo >>../apy3s_kemi_export.c
+	echo "/**" >>../apy3s_kemi_export.c
+	echo " *" >>../apy3s_kemi_export.c
+	echo " */" >>../apy3s_kemi_export.c
+	echo "static PyObject *sr_apy_kemi_exec_func_${c}(PyObject *self, PyObject *args)" \
>>../apy3s_kemi_export.c +	echo "{" >>../apy3s_kemi_export.c
+	echo "	return sr_apy_kemi_exec_func(self, args, ${c});" >>../apy3s_kemi_export.c
+	echo "}" >>../apy3s_kemi_export.c
 done
 
-echo >>../apy_kemi_export.c
-echo "/**" >>../apy_kemi_export.c
-echo " *" >>../apy_kemi_export.c
-echo " */" >>../apy_kemi_export.c
+echo >>../apy3s_kemi_export.c
+echo "/**" >>../apy3s_kemi_export.c
+echo " *" >>../apy3s_kemi_export.c
+echo " */" >>../apy3s_kemi_export.c
 
-echo "static sr_apy_kemi_export_t _sr_apy_kemi_export_list[] = {" \
>>../apy_kemi_export.c +echo "static sr_apy_kemi_export_t _sr_apy_kemi_export_list[] \
> > = {" >>../apy3s_kemi_export.c
 for (( c=0; c<CEND; c++ )); do
-	echo "	{ sr_apy_kemi_exec_func_${c}, NULL}," >>../apy_kemi_export.c
+	echo "	{ sr_apy_kemi_exec_func_${c}, NULL}," >>../apy3s_kemi_export.c
 done
-echo "	{NULL, NULL}" >>../apy_kemi_export.c
-echo "};" >>../apy_kemi_export.c
+echo "	{NULL, NULL}" >>../apy3s_kemi_export.c
+echo "};" >>../apy3s_kemi_export.c
 
-cat >> ../apy_kemi_export.c <<EOF
+cat >> ../apy3s_kemi_export.c <<EOF
 
 /**
  *


_______________________________________________
Kamailio (SER) - Development Mailing List
sr-dev@lists.kamailio.org
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic