1 /*
2 	+----------------------------------------------------------------------+
3 	| PHP Version 7                                                        |
4 	+----------------------------------------------------------------------+
5 	| Copyright (c) 1997-2018 The PHP Group                                |
6 	+----------------------------------------------------------------------+
7 	| This source file is subject to version 3.01 of the PHP license,      |
8 	| that is bundled with this package in the file LICENSE, and is        |
9 	| available through the world-wide-web at the following url:           |
10 	| http://www.php.net/license/3_01.txt                                  |
11 	| If you did not receive a copy of the PHP license and are unable to   |
12 	| obtain it through the world-wide-web, please send a note to          |
13 	| license@php.net so we can mail you a copy immediately.               |
14 	+----------------------------------------------------------------------+
15 	| Authors: Andi Gutmans <andi@php.net>                                 |
16 	|          Zeev Suraski <zeev@php.net>                                 |
17 	+----------------------------------------------------------------------+
18 */
19 
20 /* {{{ includes
21  */
22 #include "php.h"
23 #include "php_main.h"
24 #include "zend_modules.h"
25 #include "zend_compile.h"
26 #include <stdarg.h>
27 #include <stdlib.h>
28 #include <stdio.h>
29 
30 #include "ext/standard/dl.h"
31 #include "ext/standard/file.h"
32 #include "ext/standard/fsock.h"
33 #include "ext/standard/head.h"
34 #include "ext/standard/pack.h"
35 #include "ext/standard/php_browscap.h"
36 #include "ext/standard/php_crypt.h"
37 #include "ext/standard/php_dir.h"
38 #include "ext/standard/php_filestat.h"
39 #include "ext/standard/php_mail.h"
40 #include "ext/standard/php_ext_syslog.h"
41 #include "ext/standard/php_standard.h"
42 #include "ext/standard/php_lcg.h"
43 #include "ext/standard/php_array.h"
44 #include "ext/standard/php_assert.h"
45 #include "ext/reflection/php_reflection.h"
46 #if HAVE_BCMATH
47 #include "ext/bcmath/php_bcmath.h"
48 #endif
49 #if HAVE_CALENDAR
50 #include "ext/calendar/php_calendar.h"
51 #endif
52 #if HAVE_CTYPE
53 #include "ext/ctype/php_ctype.h"
54 #endif
55 #if HAVE_DATE
56 #include "ext/date/php_date.h"
57 #endif
58 #if HAVE_FTP
59 #include "ext/ftp/php_ftp.h"
60 #endif
61 #if HAVE_ICONV
62 #include "ext/iconv/php_iconv.h"
63 #endif
64 #include "ext/standard/reg.h"
65 #if HAVE_PCRE || HAVE_BUNDLED_PCRE
66 #include "ext/pcre/php_pcre.h"
67 #endif
68 #if HAVE_UODBC
69 #include "ext/odbc/php_odbc.h"
70 #endif
71 #if HAVE_PHP_SESSION
72 #include "ext/session/php_session.h"
73 #endif
74 #if HAVE_MBSTRING
75 #include "ext/mbstring/mbstring.h"
76 #endif
77 #if HAVE_TOKENIZER
78 #include "ext/tokenizer/php_tokenizer.h"
79 #endif
80 #if HAVE_ZLIB
81 #include "ext/zlib/php_zlib.h"
82 #endif
83 #if HAVE_LIBXML
84 #include "ext/libxml/php_libxml.h"
85 #if HAVE_DOM
86 #include "ext/dom/php_dom.h"
87 #endif
88 #if HAVE_SIMPLEXML
89 #include "ext/simplexml/php_simplexml.h"
90 #endif
91 #endif
92 #if HAVE_XML
93 #include "ext/xml/php_xml.h"
94 #endif
95 #if HAVE_XML && HAVE_WDDX
96 #include "ext/wddx/php_wddx.h"
97 #endif
98 #include "ext/com_dotnet/php_com_dotnet.h"
99 #ifdef HAVE_SPL
100 #include "ext/spl/php_spl.h"
101 #endif
102 #if HAVE_XML && HAVE_XMLREADER
103 #include "ext/xmlreader/php_xmlreader.h"
104 #endif
105 #if HAVE_XML && HAVE_XMLWRITER
106 #include "ext/xmlwriter/php_xmlwriter.h"
107 #endif
108 /* }}} */
109 
110 /* {{{ php_builtin_extensions[]
111  */
112 static zend_module_entry * const php_builtin_extensions[] = {
113 	phpext_standard_ptr
114 #if HAVE_BCMATH
115 	,phpext_bcmath_ptr
116 #endif
117 #if HAVE_CALENDAR
118 	,phpext_calendar_ptr
119 #endif
120 	,phpext_com_dotnet_ptr
121 #if HAVE_CTYPE
122 	,phpext_ctype_ptr
123 #endif
124 #if HAVE_DATE
125 	,phpext_date_ptr
126 #endif
127 #if HAVE_FTP
128 	,phpext_ftp_ptr
129 #endif
130 #if HAVE_HASH
131 	,phpext_hash_ptr
132 #endif
133 #if HAVE_ICONV
134 	,phpext_iconv_ptr
135 #endif
136 #if HAVE_MBSTRING
137 	,phpext_mbstring_ptr
138 #endif
139 #if HAVE_UODBC
140 	,phpext_odbc_ptr
141 #endif
142 #if HAVE_PCRE || HAVE_BUNDLED_PCRE
143 	,phpext_pcre_ptr
144 #endif
145 	,phpext_reflection_ptr
146 #if HAVE_PHP_SESSION
147 	,phpext_session_ptr
148 #endif
149 #if HAVE_TOKENIZER
150 	,phpext_tokenizer_ptr
151 #endif
152 #if HAVE_ZLIB
153 	,phpext_zlib_ptr
154 #endif
155 #if HAVE_LIBXML
156 	,phpext_libxml_ptr
157 #if HAVE_DOM
158 	,phpext_dom_ptr
159 #endif
160 #if HAVE_SIMPLEXML
161 	,phpext_simplexml_ptr
162 #endif
163 #endif
164 #if HAVE_XML
165 	,phpext_xml_ptr
166 #endif
167 #if HAVE_XML && HAVE_WDDX
168 	,phpext_wddx_ptr
169 #endif
170 #if HAVE_SPL
171 	,phpext_spl_ptr
172 #endif
173 #if HAVE_XML && HAVE_XMLREADER
174 	,phpext_xmlreader_ptr
175 #endif
176 #if HAVE_XML && HAVE_XMLWRITER
177 	,phpext_xmlwriter_ptr
178 #endif
179 };
180 /* }}} */
181 
182 #define EXTCOUNT (sizeof(php_builtin_extensions)/sizeof(zend_module_entry *))
183 
php_register_internal_extensions(void)184 PHPAPI int php_register_internal_extensions(void)
185 {
186 	return php_register_extensions(php_builtin_extensions, EXTCOUNT);
187 }
188 
189 /*
190  * Local variables:
191  * tab-width: 4
192  * c-basic-offset: 4
193  * End:
194  * vim600: sw=4 ts=4 fdm=marker
195  * vim<600: sw=4 ts=4
196  */
197