1. Enter the nginx source code directory/home/song/nginx-1.3.9/
Command line execution (the simplest parameter is to configure the installation directory)
The code is as follows: |
Copy code |
A>./configure-prefix =/home/song/test_nginx B> make C> make install |
Nginx is installed in the/home/song/test_nginx directory.
2. Import the source code to eclipse
1. Create a c project
2. Select the source code directory in location.
Based on your actual situation
3. The import is successful. Modify the project settings and clear all.
4. Set debugging parameters
C/c ++ application
Set the Directory of the configuration file started by the application
5. Modify the conf file.
Add a line of daemon off background mode to disable
Because I do not run eclipse with the root permission. For debugging purposes, change the listening port to a port greater than 1024. If you have the root permission, you do not need to modify it.
Now, end, you can start using eclipse to debug Nginx!