--- /dev/null
+# Copyright (C) Volker Lendecke <vl@samba.org> 2020
+#
+# This program is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3 of the License, or
+# (at your option) any later version.
+#
+# This program 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 General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program. If not, see <http://www.gnu.org/licenses/>.
+
+from samba.samba3.libsmb_samba_cwrapper import *
+
+class Conn(LibsmbCConn):
+ pass
static PyTypeObject py_cli_state_type = {
PyVarObject_HEAD_INIT(NULL, 0)
- .tp_name = "libsmb_samba_internal.Conn",
+ .tp_name = "libsmb_samba_cwrapper.LibsmbCConn",
.tp_basicsize = sizeof(struct py_cli_state),
.tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE,
- .tp_doc = "libsmb connection",
+ .tp_doc = "libsmb cwrapper connection",
.tp_new = py_cli_state_new,
.tp_init = (initproc)py_cli_state_init,
.tp_dealloc = (destructor)py_cli_state_dealloc,
{0},
};
-void initlibsmb_samba_internal(void);
+void initlibsmb_samba_cwrapper(void);
static struct PyModuleDef moduledef = {
PyModuleDef_HEAD_INIT,
- .m_name = "libsmb_samba_internal",
+ .m_name = "libsmb_samba_cwrapper",
.m_doc = "libsmb wrapper",
.m_size = -1,
.m_methods = py_libsmb_methods,
};
-MODULE_INIT_FUNC(libsmb_samba_internal)
+MODULE_INIT_FUNC(libsmb_samba_cwrapper)
{
PyObject *m = NULL;
return NULL;
}
Py_INCREF(&py_cli_state_type);
- PyModule_AddObject(m, "Conn", (PyObject *)&py_cli_state_type);
+ PyModule_AddObject(m, "LibsmbCConn", (PyObject *)&py_cli_state_type);
#define ADD_FLAGS(val) PyModule_AddObject(m, #val, PyLong_FromLong(val))
bld.SAMBA3_PYTHON('pylibsmb',
source='libsmb/pylibsmb.c',
deps='smbclient samba-credentials %s' % pycredentials,
- realname='samba/samba3/libsmb_samba_internal.so'
+ realname='samba/samba3/libsmb_samba_cwrapper.so'
)
bld.SAMBA3_PYTHON('pymdscli',