From a044ad95f077300304af0367d98435ed44f663c4 Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sat, 3 Aug 2013 12:59:36 -0500 Subject: [PATCH 1/9] - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild --- http-parser.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/http-parser.spec b/http-parser.spec index 8d5bde4..0623903 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -8,7 +8,7 @@ Name: http-parser Version: %{somajor}.%{sominor} -Release: 4.%{git_date}git%{git_commit_hash}%{?dist} +Release: 5.%{git_date}git%{git_commit_hash}%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -102,6 +102,9 @@ rm -rf %{buildroot} %changelog +* Sat Aug 03 2013 Fedora Release Engineering - 2.0-5.20121128gitcd01361 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild + * Thu Feb 14 2013 Fedora Release Engineering - 2.0-4.20121128gitcd01361 - Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild From 13dbe10fe62958546c1e4fb1db0d35540b77f5ca Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Sat, 7 Jun 2014 15:30:19 -0500 Subject: [PATCH 2/9] - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild --- http-parser.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/http-parser.spec b/http-parser.spec index 0623903..25e7cbb 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -8,7 +8,7 @@ Name: http-parser Version: %{somajor}.%{sominor} -Release: 5.%{git_date}git%{git_commit_hash}%{?dist} +Release: 6.%{git_date}git%{git_commit_hash}%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -102,6 +102,9 @@ rm -rf %{buildroot} %changelog +* Sat Jun 07 2014 Fedora Release Engineering - 2.0-6.20121128gitcd01361 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild + * Sat Aug 03 2013 Fedora Release Engineering - 2.0-5.20121128gitcd01361 - Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild From 72e8ca51be93592abef65b645ee5f6af4c647450 Mon Sep 17 00:00:00 2001 From: Peter Robinson Date: Sat, 16 Aug 2014 20:44:31 +0000 Subject: [PATCH 3/9] - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild --- http-parser.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/http-parser.spec b/http-parser.spec index 25e7cbb..7e931ca 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -8,7 +8,7 @@ Name: http-parser Version: %{somajor}.%{sominor} -Release: 6.%{git_date}git%{git_commit_hash}%{?dist} +Release: 7.%{git_date}git%{git_commit_hash}%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -102,6 +102,9 @@ rm -rf %{buildroot} %changelog +* Sat Aug 16 2014 Fedora Release Engineering - 2.0-7.20121128gitcd01361 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild + * Sat Jun 07 2014 Fedora Release Engineering - 2.0-6.20121128gitcd01361 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild From 62a0c6e8455199db676ad84df86db9be6bfeb73f Mon Sep 17 00:00:00 2001 From: Kalev Lember Date: Sat, 2 May 2015 14:21:32 +0200 Subject: [PATCH 4/9] Rebuilt for GCC 5 C++11 ABI change --- http-parser.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/http-parser.spec b/http-parser.spec index 7e931ca..a19f83c 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -8,7 +8,7 @@ Name: http-parser Version: %{somajor}.%{sominor} -Release: 7.%{git_date}git%{git_commit_hash}%{?dist} +Release: 8.%{git_date}git%{git_commit_hash}%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -102,6 +102,9 @@ rm -rf %{buildroot} %changelog +* Sat May 02 2015 Kalev Lember - 2.0-8.20121128gitcd01361 +- Rebuilt for GCC 5 C++11 ABI change + * Sat Aug 16 2014 Fedora Release Engineering - 2.0-7.20121128gitcd01361 - Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild From beb3289e63e74b837d295e91a675fbb96d1f360a Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Wed, 17 Jun 2015 10:35:26 +0000 Subject: [PATCH 5/9] - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild --- http-parser.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/http-parser.spec b/http-parser.spec index a19f83c..873f1a6 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -8,7 +8,7 @@ Name: http-parser Version: %{somajor}.%{sominor} -Release: 8.%{git_date}git%{git_commit_hash}%{?dist} +Release: 9.%{git_date}git%{git_commit_hash}%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -102,6 +102,9 @@ rm -rf %{buildroot} %changelog +* Wed Jun 17 2015 Fedora Release Engineering - 2.0-9.20121128gitcd01361 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild + * Sat May 02 2015 Kalev Lember - 2.0-8.20121128gitcd01361 - Rebuilt for GCC 5 C++11 ABI change From 8567b0f9b09ac3018e013e27c7de9d5b16a41b9c Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 1 Dec 2015 15:55:13 -0500 Subject: [PATCH 6/9] Upgrade to version 2.6.0 - Change to new upstream at https://github.com/nodejs/http-parser/ --- .gitignore | 1 + http-parser.spec | 27 +++++++++++++++------------ sources | 2 +- 3 files changed, 17 insertions(+), 13 deletions(-) diff --git a/.gitignore b/.gitignore index 1e2af03..e847538 100644 --- a/.gitignore +++ b/.gitignore @@ -3,3 +3,4 @@ /joyent-http-parser-v2.0-0-g3fb4e06.tar.gz /joyent-http-parser-v2.0-5-g245f6f0.tar.gz /joyent-http-parser-v2.0-7-gcd01361.tar.gz +/v2.6.0.tar.gz diff --git a/http-parser.spec b/http-parser.spec index 873f1a6..79ed465 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -1,21 +1,18 @@ # we use the upstream version from http_parser.h as the SONAME %global somajor 2 -%global sominor 0 - -%global git_date 20121128 -%global git_commit_hash cd01361 -%global github_seq 7 +%global sominor 6 +%global sopoint 0 Name: http-parser -Version: %{somajor}.%{sominor} -Release: 9.%{git_date}git%{git_commit_hash}%{?dist} +Version: %{somajor}.%{sominor}.%{sopoint} +Release: 1%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries License: MIT URL: http://github.com/joyent/http-parser -# download from https://github.com/joyent/http-parser/tarball/%%{version} -Source0: joyent-http-parser-v%{version}-%{github_seq}-g%{git_commit_hash}.tar.gz + +Source0: https://github.com/nodejs/http-parser/archive/v%{version}.tar.gz BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) # Build shared library with SONAME using gyp and remove -O flags so optflags take over @@ -43,7 +40,7 @@ Development headers and libraries for http-parser. %prep -%setup -q -n joyent-http-parser-%{git_commit_hash} +%setup -q -n http-parser-%{version} %patch1 @@ -91,7 +88,8 @@ rm -rf %{buildroot} %defattr(-,root,root,-) %{_libdir}/libhttp_parser.so.* %{_libdir}/libhttp_parser_strict.so.* -%doc AUTHORS CONTRIBUTIONS LICENSE-MIT README.md +%doc AUTHORS README.md +%license LICENSE-MIT %files devel @@ -102,6 +100,10 @@ rm -rf %{buildroot} %changelog +* Tue Dec 01 2015 Stephen Gallagher 2.6.0-1 +- Upgrade to version 2.6.0 +- Change to new upstream at https://github.com/nodejs/http-parser/ + * Wed Jun 17 2015 Fedora Release Engineering - 2.0-9.20121128gitcd01361 - Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild @@ -163,4 +165,5 @@ rm -rf %{buildroot} - Call ldconfig (Peter Lemenkov) * Fri Sep 17 2010 Lubomir Rintel - 0.3-1.20100911git -- Initial packaging \ No newline at end of file +- Initial packaging + diff --git a/sources b/sources index e2626bb..197dba4 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -340f2aab333c435cbaf49a4949645a06 joyent-http-parser-v2.0-7-gcd01361.tar.gz +63033f3e657ee46c5fef6e53e4d9886b v2.6.0.tar.gz From 049e9b512a653128466351646372e75724d2ae2d Mon Sep 17 00:00:00 2001 From: Dennis Gilmore Date: Wed, 3 Feb 2016 23:55:50 +0000 Subject: [PATCH 7/9] - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild --- http-parser.spec | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/http-parser.spec b/http-parser.spec index 79ed465..a899804 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -5,7 +5,7 @@ Name: http-parser Version: %{somajor}.%{sominor}.%{sopoint} -Release: 1%{?dist} +Release: 2%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -100,6 +100,9 @@ rm -rf %{buildroot} %changelog +* Wed Feb 03 2016 Fedora Release Engineering - 2.6.0-2 +- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild + * Tue Dec 01 2015 Stephen Gallagher 2.6.0-1 - Upgrade to version 2.6.0 - Change to new upstream at https://github.com/nodejs/http-parser/ From 5b87ba4c830faea0351534051191ba27b3b33520 Mon Sep 17 00:00:00 2001 From: Stephen Gallagher Date: Tue, 16 Aug 2016 09:41:07 -0400 Subject: [PATCH 8/9] Upgrade to version 2.7.1 --- .gitignore | 1 + http-parser.spec | 7 +++++-- sources | 2 +- 3 files changed, 7 insertions(+), 3 deletions(-) diff --git a/.gitignore b/.gitignore index e847538..c3e8ebe 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ /joyent-http-parser-v2.0-5-g245f6f0.tar.gz /joyent-http-parser-v2.0-7-gcd01361.tar.gz /v2.6.0.tar.gz +/v2.7.1.tar.gz diff --git a/http-parser.spec b/http-parser.spec index a899804..b900a5f 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -1,7 +1,7 @@ # we use the upstream version from http_parser.h as the SONAME %global somajor 2 -%global sominor 6 -%global sopoint 0 +%global sominor 7 +%global sopoint 1 Name: http-parser Version: %{somajor}.%{sominor}.%{sopoint} @@ -100,6 +100,9 @@ rm -rf %{buildroot} %changelog +* Tue Aug 16 2016 Stephen Gallagher - 2.7.1-2 +- Upgrade to version 2.7.1 + * Wed Feb 03 2016 Fedora Release Engineering - 2.6.0-2 - Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild diff --git a/sources b/sources index 197dba4..b9c40b2 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -63033f3e657ee46c5fef6e53e4d9886b v2.6.0.tar.gz +31c6fefb6208b16d19b3f990e71cb04a v2.7.1.tar.gz From 05ce28f22ea602202f70e1b3998a1d99627f3085 Mon Sep 17 00:00:00 2001 From: Nathaniel McCallum Date: Tue, 25 Oct 2016 16:18:34 -0400 Subject: [PATCH 9/9] Add http-parser-status.patch from upstream --- http-parser-status.patch | 98 ++++++++++++++++++++++++++++++++++++++++ http-parser.spec | 9 ++-- 2 files changed, 104 insertions(+), 3 deletions(-) create mode 100644 http-parser-status.patch diff --git a/http-parser-status.patch b/http-parser-status.patch new file mode 100644 index 0000000..451104c --- /dev/null +++ b/http-parser-status.patch @@ -0,0 +1,98 @@ +From 335850f6b868d3411968cbf5a4d59fe619dee36f Mon Sep 17 00:00:00 2001 +From: Nathaniel McCallum +Date: Thu, 6 Oct 2016 02:03:36 -0400 +Subject: [PATCH] parser: HTTP_STATUS_MAP(XX) and enum http_status + +This patch provides an enum for the standardized HTTP status codes. +Additionally, the HTTP_STATUS_MAP(XX) can be used for other purposes as +well, such as code-to-name lookups and code-based switch statements. + +PR-URL: https://github.com/nodejs/http-parser/pull/337 +Reviewed-By: Fedor Indutny +Reviewed-By: Brian White +Reviewed-By: Ben Noordhuis +--- + http_parser.h | 70 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 70 insertions(+) + +diff --git a/http_parser.h b/http_parser.h +index ea26394..45c72a0 100644 +--- a/http_parser.h ++++ b/http_parser.h +@@ -90,6 +90,76 @@ typedef int (*http_data_cb) (http_parser*, const char *at, size_t length); + typedef int (*http_cb) (http_parser*); + + ++/* Status Codes */ ++#define HTTP_STATUS_MAP(XX) \ ++ XX(100, CONTINUE, Continue) \ ++ XX(101, SWITCHING_PROTOCOLS, Switching Protocols) \ ++ XX(102, PROCESSING, Processing) \ ++ XX(200, OK, OK) \ ++ XX(201, CREATED, Created) \ ++ XX(202, ACCEPTED, Accepted) \ ++ XX(203, NON_AUTHORITATIVE_INFORMATION, Non-Authoritative Information) \ ++ XX(204, NO_CONTENT, No Content) \ ++ XX(205, RESET_CONTENT, Reset Content) \ ++ XX(206, PARTIAL_CONTENT, Partial Content) \ ++ XX(207, MULTI_STATUS, Multi-Status) \ ++ XX(208, ALREADY_REPORTED, Already Reported) \ ++ XX(226, IM_USED, IM Used) \ ++ XX(300, MULTIPLE_CHOICES, Multiple Choices) \ ++ XX(301, MOVED_PERMANENTLY, Moved Permanently) \ ++ XX(302, FOUND, Found) \ ++ XX(303, SEE_OTHER, See Other) \ ++ XX(304, NOT_MODIFIED, Not Modified) \ ++ XX(305, USE_PROXY, Use Proxy) \ ++ XX(307, TEMPORARY_REDIRECT, Temporary Redirect) \ ++ XX(308, PERMANENT_REDIRECT, Permanent Redirect) \ ++ XX(400, BAD_REQUEST, Bad Request) \ ++ XX(401, UNAUTHORIZED, Unauthorized) \ ++ XX(402, PAYMENT_REQUIRED, Payment Required) \ ++ XX(403, FORBIDDEN, Forbidden) \ ++ XX(404, NOT_FOUND, Not Found) \ ++ XX(405, METHOD_NOT_ALLOWED, Method Not Allowed) \ ++ XX(406, NOT_ACCEPTABLE, Not Acceptable) \ ++ XX(407, PROXY_AUTHENTICATION_REQUIRED, Proxy Authentication Required) \ ++ XX(408, REQUEST_TIMEOUT, Request Timeout) \ ++ XX(409, CONFLICT, Conflict) \ ++ XX(410, GONE, Gone) \ ++ XX(411, LENGTH_REQUIRED, Length Required) \ ++ XX(412, PRECONDITION_FAILED, Precondition Failed) \ ++ XX(413, PAYLOAD_TOO_LARGE, Payload Too Large) \ ++ XX(414, URI_TOO_LONG, URI Too Long) \ ++ XX(415, UNSUPPORTED_MEDIA_TYPE, Unsupported Media Type) \ ++ XX(416, RANGE_NOT_SATISFIABLE, Range Not Satisfiable) \ ++ XX(417, EXPECTATION_FAILED, Expectation Failed) \ ++ XX(421, MISDIRECTED_REQUEST, Misdirected Request) \ ++ XX(422, UNPROCESSABLE_ENTITY, Unprocessable Entity) \ ++ XX(423, LOCKED, Locked) \ ++ XX(424, FAILED_DEPENDENCY, Failed Dependency) \ ++ XX(426, UPGRADE_REQUIRED, Upgrade Required) \ ++ XX(428, PRECONDITION_REQUIRED, Precondition Required) \ ++ XX(429, TOO_MANY_REQUESTS, Too Many Requests) \ ++ XX(431, REQUEST_HEADER_FIELDS_TOO_LARGE, Request Header Fields Too Large) \ ++ XX(451, UNAVAILABLE_FOR_LEGAL_REASONS, Unavailable For Legal Reasons) \ ++ XX(500, INTERNAL_SERVER_ERROR, Internal Server Error) \ ++ XX(501, NOT_IMPLEMENTED, Not Implemented) \ ++ XX(502, BAD_GATEWAY, Bad Gateway) \ ++ XX(503, SERVICE_UNAVAILABLE, Service Unavailable) \ ++ XX(504, GATEWAY_TIMEOUT, Gateway Timeout) \ ++ XX(505, HTTP_VERSION_NOT_SUPPORTED, HTTP Version Not Supported) \ ++ XX(506, VARIANT_ALSO_NEGOTIATES, Variant Also Negotiates) \ ++ XX(507, INSUFFICIENT_STORAGE, Insufficient Storage) \ ++ XX(508, LOOP_DETECTED, Loop Detected) \ ++ XX(510, NOT_EXTENDED, Not Extended) \ ++ XX(511, NETWORK_AUTHENTICATION_REQUIRED, Network Authentication Required) \ ++ ++enum http_status ++ { ++#define XX(num, name, string) HTTP_STATUS_##name = num, ++ HTTP_STATUS_MAP(XX) ++#undef XX ++ }; ++ ++ + /* Request Methods */ + #define HTTP_METHOD_MAP(XX) \ + XX(0, DELETE, DELETE) \ diff --git a/http-parser.spec b/http-parser.spec index b900a5f..33c20b6 100644 --- a/http-parser.spec +++ b/http-parser.spec @@ -5,7 +5,7 @@ Name: http-parser Version: %{somajor}.%{sominor}.%{sopoint} -Release: 2%{?dist} +Release: 3%{?dist} Summary: HTTP request/response parser for C Group: System Environment/Libraries @@ -18,6 +18,7 @@ BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX) # Build shared library with SONAME using gyp and remove -O flags so optflags take over # TODO: do this nicely upstream Patch1: http-parser-gyp-sharedlib.patch +Patch2: http-parser-status.patch BuildRequires: gyp @@ -40,8 +41,7 @@ Development headers and libraries for http-parser. %prep -%setup -q -n http-parser-%{version} -%patch1 +%autosetup -n http-parser-%{version} %build @@ -100,6 +100,9 @@ rm -rf %{buildroot} %changelog +* Tue Oct 25 2016 Nathaniel McCallum - 2.7.1-3 +- Add (upstreamed) status code patch + * Tue Aug 16 2016 Stephen Gallagher - 2.7.1-2 - Upgrade to version 2.7.1