Project

General

Profile

DeveloperEnvironmentSetup » History » Version 11

Andreas Kohlbecker, 11/08/2016 09:55 AM

1 11 Andreas Kohlbecker
# THIS PAGE IS OUT DATED
2
3
We no longer recommend using eclipse for developing the DataPortal. PhpStorm is a much better choice!
4
5
----
6
7
8 1 Andreas Müller
This page wants to give help while setting up different development environments.
9
10
There may be other places in the wiki with this kind of information. If you find some please move them here.
11
12
13 5 Niels Hoffmann
If you are looking for instructions on how to set up a development and test environment for OS X, see wiki:DeveloperEnvironmentSetupOsX
14 4 Niels Hoffmann
15
16 3 Andreas Müller
{{>toc}}
17
18
19
20
21
# Eclipse
22
23
24 1 Andreas Müller
25
## Local dataportal development and test environment
26 5 Niels Hoffmann
27 1 Andreas Müller
28
29
1) Install Apache Server 2.2.x
30
31
32
2) Install PHP
33
34
35
2a) Include the path to libmysql.dll (e.g.: C:\Programme\php-5.2.6) into your Path 
36
37
38
2b) Try to run Apache server
39
40
41
42
43
3) Insert the following into the appache conf\httpd.conf file(below the LoadModule part at about Line 120) and adapt them accordingly:
44
45
46
      1. PHP modules
47
48
49
  1. php5
50
51
52
LoadModule php5_module "c:/Programme/php-5.2.6/php5apache2_2.dll"
53
54
55
1. configure the path to php.ini
56
57
58
PHPIniDir "c:/Programme/php-5.2.6/"
59
60
61
62
63 7 Francisco Revilla
4) Install PDT (PHP) plugin in elcipse from http://www.eclipse.org/pdt/ (I made it with the update http://download.eclipse.org/tools/pdt/updates/2.0/ because the version 2.2 does not work at 18.09.09)
64 1 Andreas Müller
65
66
67
5)Give the according rights to the eclipse project within  appache ..\conf\httpd.conf. E.g.:
68
69
 
70
<Directory "D:/eclipse_workspace/Drupal5">
71
72
73
	AllowOverride All
74
75
76
	Options Indexes
77
78
79
	Order allow,deny
80
81
82
	Allow from all
83
84
85
</Directory>
86
87
88
89
or use apache only localy by adding:
90
91
92
93
DocumentRoot "D:/eclipse_workspace/"
94
95
96 6 Andreas Kohlbecker
6)Add aliases for different projects to appache ..\conf\httpd.conf. E.g.:
97 1 Andreas Müller
98
99
100
    Alias "/drupal_test"     "D:/eclipse_workspace/Drupal5"
101
102
103
    Alias "/expertsdb"       "D:/eclipse_workspace/Drupal5"
104
105
106
    Alias "/drupal_demo"     "D:/eclipse_workspace/Drupal5"
107
108
109
    Alias "/cdm_dataportal"  "D:/eclipse_workspace/Drupal5"
110
111
112
    Alias "/drupal6"         "D:/eclipse_workspace/Drupal6"
113
114
115
116
117 6 Andreas Kohlbecker
7) Install run-jetty-run eclipse plugin from http://code.google.com/p/run-jetty-run/ ( includes Jetty server; compatible with eclipse 3.4.1 ) 
118 1 Andreas Müller
119
120
121
8) Download php_xdebug-xxx.dll from http://xdebug.org
122
123
124
Move php_xdebug-xxx.dll into your ..\PHP\ext folder
125
126
127
128
9) Add the following to your php.ini and adapt accordingly:
129
130
131
[xdebug]
132
133
134
zend_extension_ts=C:\Program Files\php-5.2.1\ext\php_xdebug-2.0.1-5.2.1.dll
135
136
137
xdebug.remote_enable=1
138
139
140
xdebug.remote_handler=dbgp
141
142
143
xdebug.remote_mode=req
144
145
146
xdebug.remote_port=9000
147
148
149
xdebug.remote_host=127.0.0.1
150
151
152
xdebug.remote_log=C:\Program Files\Apache Software Foundation\Apache2.2\logs\xdebug_remote.log
153
154
155
xdebug.profiler_enable = 0
156
157
158
xdebug.profiler_enable_trigger = 0
159
160
161
;     Type: integer, Default value: 0
162
163
164
;     When this setting is set to 1, you can trigger the generation of profiler files by using the XDEBUG_PROFILE GET/POST parameter. This will then write the profiler data to defined directory.
165
166
167
xdebug.profiler_output_dir = D:\tmp
168
169
170
; xdebug.profiler_output_name
171
172
173
;     Type: string, Default value: cachegrind.out.%p
174
175
176
;     This setting determines the name of the file that is used to dump traces into. The setting specifies the format with format specifiers, very similar to sprintf() and strftime(). There are several format specifiers that can be used to format the file name.
177 8 Andreas Kohlbecker
178
179
180
181
### Problems and Solutions
182
183
184 9 Andreas Kohlbecker
185
#### xdebug does not work within Eclipse/PDT. Starting the debug session is stuck at 57% with the message "waiting for XDebug session"
186 8 Andreas Kohlbecker
187
188
This as been observed under WinXP, where the Checkpoint VPN-1 SecureClient, is also using port 9000. Therefore Eclipse/PDT could never open port 9000 for communication with the xdebug server. Change the port of xdebug in your php.ini and in the eclipse settings