{"id":3315,"date":"2015-06-19T20:58:18","date_gmt":"2015-06-19T19:58:18","guid":{"rendered":"https:\/\/blog.ed.gs\/?p=3315"},"modified":"2015-06-19T20:58:18","modified_gmt":"2015-06-19T19:58:18","slug":"add-build-options-to-nginx-via-apt-get-ubuntu","status":"publish","type":"post","link":"https:\/\/ed.gs\/2015\/06\/19\/add-build-options-to-nginx-via-apt-get-ubuntu\/","title":{"rendered":"Add Build Options To Nginx Via Apt-Get Ubuntu"},"content":{"rendered":"
These instructions aren’t mine, but are a slightly modified version of the ones listed on serverfault.com<\/a> thanks to cwd<\/a> as a reminder for myself with upcoming Nginx updates.<\/p>\n CD to a location you’re happy to work in with the source files:<\/p>\n Install dpkg-dev:<\/p>\n Add repository:<\/p>\n Edit \/etc\/apt\/sources.list.d\/nginx-stable-*.list, add uncomment dpkg-src:<\/p>\n note: (the previous step may have already been automatically performed on Ubuntu >= 12.04 – also make sure that you change release-name-here to reflect your version, the most important part is to uncomment the deb-src field as it will use that to download the source in the upcoming step)<\/p>\n Resynchronize the package index files:<\/p>\n Get sources:<\/p>\n Build dependencies:<\/p>\n Edit nginx-*(version-here)\/debian\/rules (update the section you want to install, be it light\/full\/common e.g. extras_configure_flags :=):<\/p>\n Build package:<\/p>\n Install packages (change the deb version and OS name as needed):<\/p>\n These instructions aren’t mine, but are a slightly modified version of the ones listed on serverfault.com thanks to cwd as a reminder for myself with upcoming Nginx updates. CD to a location you’re happy to work in with the source files: cd /usr/src Install dpkg-dev: sudo apt-get install dpkg-dev Add repository: sudo add-apt-repository ppa:nginx/stable Edit […]<\/p>\n","protected":false},"author":2,"featured_media":3404,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"ep_exclude_from_search":false},"categories":[13,28,32,41,46],"tags":[],"yoast_head":"\ncd /usr/src<\/pre>\n
sudo apt-get install dpkg-dev<\/pre>\n
sudo add-apt-repository ppa:nginx/stable<\/pre>\n
deb-src http://ppa.launchpad.net/nginx/stable/ubuntu release-name-here main<\/pre>\n
sudo apt-get update<\/pre>\n
apt-get source nginx<\/pre>\n
sudo apt-get build-dep nginx<\/pre>\n
--with-threads<\/pre>\n
cd nginx-*(version-here) && dpkg-buildpackage -b<\/pre>\n
dpkg --install nginx-common_1.2.4-2ubuntu0ppa1~precise_all.deb\ndpkg --install nginx-full_1.2.4-2ubuntu0ppa1~precise_amd64.deb<\/pre>\n","protected":false},"excerpt":{"rendered":"