Compile and debug the Nginx module using eclipse in Linux

Source: Internet
Author: User

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!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.