Browse code

core, lib, modules: restructured source code tree

- new folder src/ to hold the source code for main project applications
- main.c is in src/
- all core files are subfolder are in src/core/
- modules are in src/modules/
- libs are in src/lib/
- application Makefiles are in src/
- application binary is built in src/ (src/kamailio)

Daniel-Constantin Mierla authored on 07/12/2016 11:03:51
Showing 1 changed files
1 1
deleted file mode 100644
... ...
@@ -1,83 +0,0 @@
1
-/* 
2
- * Copyright (C) 2009 iptelorg GmbH
3
- *
4
- * This file is part of Kamailio, a free SIP server.
5
- *
6
- * Permission to use, copy, modify, and distribute this software for any
7
- * purpose with or without fee is hereby granted, provided that the above
8
- * copyright notice and this permission notice appear in all copies.
9
- *
10
- * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11
- * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12
- * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13
- * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14
- * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15
- * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16
- * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17
- */
18
-
19
-/**
20
- * \file
21
- * \brief Helper definitions for internal memory manager
22
- * 
23
- * Helper definitions for internal memory manager, defines for src location
24
- * (function name, module a.s.o.), used for recording a *malloc()/ *free()
25
- * caller. Expects MOD_NAME defined for modules (if it's not defined "core"
26
- * will be assumed).
27
- * 
28
- * Defines:
29
- * - _SRC_FUNCTION_  - current function name
30
- * - _SRC_FILENAME_  - current .c filename
31
- * - _SRC_LINE_      - current line
32
- * - _SRC_MODULE_    - module name, lib name or "<core>" (depends on MOD_NAME
33
- * being properly set)
34
- * - _SRC_LOC_       - module name + file name
35
- * \ingroup mem
36
- */
37
-
38
-
39
-#ifndef __src_loc_h
40
-#define __src_loc_h
41
-
42
-
43
-/* C >= 99 has __func__, older gcc versions have __FUNCTION__ */
44
-#ifndef _SRC_FUNCTION_
45
-#	if __STDC_VERSION__ < 199901L
46
-#		if __GNUC__ >= 2
47
-#			define _SRC_FUNCTION_ __FUNCTION__
48
-#		else
49
-#			define _SRC_FUNCTION_ ""
50
-#		endif
51
-#	else
52
-#		define _SRC_FUNCTION_ __func__
53
-#	endif /* __STDC_VERSION_ < 199901L */
54
-#endif /* _FUNC_NAME_ */
55
-
56
-
57
-#ifndef _SRC_FILENAME_
58
-#	define _SRC_FILENAME_ __FILE__
59
-#endif /* _SRC_FILENAME_ */
60
-
61
-
62
-#ifndef _SRC_LINE_
63
-#	define _SRC_LINE_ __LINE__
64
-#endif /* _SRC_LINE_ */
65
-
66
-
67
-#ifndef _SRC_MODULE_
68
-#	ifdef MOD_NAME
69
-#		define _SRC_MODULE_ MOD_NAME
70
-#	else
71
-#		define _SRC_MODULE_ "core"
72
-#	endif /* MOD_NAME */
73
-#endif /* _SRC_MODULE_ */
74
-
75
-
76
-#ifndef _SRC_LOC_
77
-#	define _SRC_LOC_ _SRC_MODULE_ ": " _SRC_FILENAME_
78
-#endif /*_SRC_LOC_ */
79
-
80
-
81
-#endif /*__src_loc_h*/
82
-
83
-/* vi: set ts=4 sw=4 tw=79:ai:cindent: */
Browse code

core: mem - references use now 'core' for operations done from code in core

- previously it was '<core>'
- makes it more coherent, given the case of module names

Stefan Mititelu authored on 02/11/2015 12:45:25 • Daniel-Constantin Mierla committed on 02/11/2015 12:45:25
Showing 1 changed files
... ...
@@ -68,7 +68,7 @@
68 68
 #	ifdef MOD_NAME
69 69
 #		define _SRC_MODULE_ MOD_NAME
70 70
 #	else
71
-#		define _SRC_MODULE_ "<core>"
71
+#		define _SRC_MODULE_ "core"
72 72
 #	endif /* MOD_NAME */
73 73
 #endif /* _SRC_MODULE_ */
74 74
 
Browse code

mem Remove SVN ID, remove history

Olle E. Johansson authored on 25/02/2015 08:12:38
Showing 1 changed files
... ...
@@ -1,6 +1,8 @@
1 1
 /* 
2 2
  * Copyright (C) 2009 iptelorg GmbH
3 3
  *
4
+ * This file is part of Kamailio, a free SIP server.
5
+ *
4 6
  * Permission to use, copy, modify, and distribute this software for any
5 7
  * purpose with or without fee is hereby granted, provided that the above
6 8
  * copyright notice and this permission notice appear in all copies.
... ...
@@ -14,12 +16,6 @@
14 16
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15 17
  */
16 18
 
17
-/*
18
- * History:
19
- * --------
20
- *  2009-10-08  initial version (andrei)
21
-*/
22
-
23 19
 /**
24 20
  * \file
25 21
  * \brief Helper definitions for internal memory manager
Browse code

mem: initial doxygen documentation for MM, small whitespace changes

Henning Westerholt authored on 13/07/2011 22:11:48
Showing 1 changed files
... ...
@@ -1,6 +1,4 @@
1 1
 /* 
2
- * $Id$
3
- * 
4 2
  * Copyright (C) 2009 iptelorg GmbH
5 3
  *
6 4
  * Permission to use, copy, modify, and distribute this software for any
... ...
@@ -15,27 +13,33 @@
15 13
  * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16 14
  * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17 15
  */
18
-/*
19
- * mem/src_loc.h - defines for src location ( function name, module a.s.o.),
20
- *  used for recording a *malloc()/ *free() caller.
21
- *
22
- * Expects MOD_NAME defined for modules (if it's not defined "core" will be
23
- * assumed).
24
- * Defines:
25
- *  _SRC_FUNCTION_  - current function name
26
- *  _SRC_FILENAME_  - current .c filename
27
- *  _SRC_LINE_      - current line
28
- *  _SRC_MODULE_    - module name, lib name or "<core>" (depends on MOD_NAME
29
- *                    being properly set)
30
- *  _SRC_LOC_       - module name + file name
31
- *
32
- */
16
+
33 17
 /*
34 18
  * History:
35 19
  * --------
36 20
  *  2009-10-08  initial version (andrei)
37 21
 */
38 22
 
23
+/**
24
+ * \file
25
+ * \brief Helper definitions for internal memory manager
26
+ * 
27
+ * Helper definitions for internal memory manager, defines for src location
28
+ * (function name, module a.s.o.), used for recording a *malloc()/ *free()
29
+ * caller. Expects MOD_NAME defined for modules (if it's not defined "core"
30
+ * will be assumed).
31
+ * 
32
+ * Defines:
33
+ * - _SRC_FUNCTION_  - current function name
34
+ * - _SRC_FILENAME_  - current .c filename
35
+ * - _SRC_LINE_      - current line
36
+ * - _SRC_MODULE_    - module name, lib name or "<core>" (depends on MOD_NAME
37
+ * being properly set)
38
+ * - _SRC_LOC_       - module name + file name
39
+ * \ingroup mem
40
+ */
41
+
42
+
39 43
 #ifndef __src_loc_h
40 44
 #define __src_loc_h
41 45
 
Browse code

mem: include the module name in the debugging info

- use <module_name: file> when recording the filename information
for debugging (DBQ_QM_MALLOC defined)
- added a new file that should define in a portable way the
various location info (file, function, a.s.o.)

Andrei Pelinescu-Onciul authored on 08/10/2009 09:33:25
Showing 1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,83 @@
1
+/* 
2
+ * $Id$
3
+ * 
4
+ * Copyright (C) 2009 iptelorg GmbH
5
+ *
6
+ * Permission to use, copy, modify, and distribute this software for any
7
+ * purpose with or without fee is hereby granted, provided that the above
8
+ * copyright notice and this permission notice appear in all copies.
9
+ *
10
+ * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11
+ * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12
+ * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13
+ * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14
+ * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15
+ * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16
+ * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
17
+ */
18
+/*
19
+ * mem/src_loc.h - defines for src location ( function name, module a.s.o.),
20
+ *  used for recording a *malloc()/ *free() caller.
21
+ *
22
+ * Expects MOD_NAME defined for modules (if it's not defined "core" will be
23
+ * assumed).
24
+ * Defines:
25
+ *  _SRC_FUNCTION_  - current function name
26
+ *  _SRC_FILENAME_  - current .c filename
27
+ *  _SRC_LINE_      - current line
28
+ *  _SRC_MODULE_    - module name, lib name or "<core>" (depends on MOD_NAME
29
+ *                    being properly set)
30
+ *  _SRC_LOC_       - module name + file name
31
+ *
32
+ */
33
+/*
34
+ * History:
35
+ * --------
36
+ *  2009-10-08  initial version (andrei)
37
+*/
38
+
39
+#ifndef __src_loc_h
40
+#define __src_loc_h
41
+
42
+
43
+/* C >= 99 has __func__, older gcc versions have __FUNCTION__ */
44
+#ifndef _SRC_FUNCTION_
45
+#	if __STDC_VERSION__ < 199901L
46
+#		if __GNUC__ >= 2
47
+#			define _SRC_FUNCTION_ __FUNCTION__
48
+#		else
49
+#			define _SRC_FUNCTION_ ""
50
+#		endif
51
+#	else
52
+#		define _SRC_FUNCTION_ __func__
53
+#	endif /* __STDC_VERSION_ < 199901L */
54
+#endif /* _FUNC_NAME_ */
55
+
56
+
57
+#ifndef _SRC_FILENAME_
58
+#	define _SRC_FILENAME_ __FILE__
59
+#endif /* _SRC_FILENAME_ */
60
+
61
+
62
+#ifndef _SRC_LINE_
63
+#	define _SRC_LINE_ __LINE__
64
+#endif /* _SRC_LINE_ */
65
+
66
+
67
+#ifndef _SRC_MODULE_
68
+#	ifdef MOD_NAME
69
+#		define _SRC_MODULE_ MOD_NAME
70
+#	else
71
+#		define _SRC_MODULE_ "<core>"
72
+#	endif /* MOD_NAME */
73
+#endif /* _SRC_MODULE_ */
74
+
75
+
76
+#ifndef _SRC_LOC_
77
+#	define _SRC_LOC_ _SRC_MODULE_ ": " _SRC_FILENAME_
78
+#endif /*_SRC_LOC_ */
79
+
80
+
81
+#endif /*__src_loc_h*/
82
+
83
+/* vi: set ts=4 sw=4 tw=79:ai:cindent: */