Skip to content
This repository has been archived by the owner on Jun 30, 2021. It is now read-only.

Commit

Permalink
Merge branch 'release/1.2.17-beta'
Browse files Browse the repository at this point in the history
  • Loading branch information
NathanFrench committed Sep 3, 2018
2 parents 6cb403a + b503dff commit c42cbe3
Show file tree
Hide file tree
Showing 24 changed files with 3,235 additions and 788 deletions.
1 change: 1 addition & 0 deletions .ycm_extra_conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
'-xc',
'-I/usr/lib/',
'-I/usr/include/',
'-I./include',
]

SOURCE_EXTENSIONS = [
Expand Down
18 changes: 13 additions & 5 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ cmake_minimum_required(VERSION 3.1)

list(APPEND CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake)

project(libevhtp VERSION "1.2.17.0")
project(libevhtp VERSION "1.2.17.1")

# For us YCM users.
set(CMAKE_EXPORT_COMPILE_COMMANDS ON)
Expand All @@ -22,10 +22,13 @@ check_include_files(stdlib.h HAVE_STDLIB_H)
check_include_files(string.h HAVE_STRING_H)
check_include_files(stdint.h HAVE_STDINT_H)
check_include_files(errno.h HAVE_ERRNO_H)
check_include_files(signal.h HAVE_SIGNAL_H)
check_include_files(strings.h HAVE_STRINGS_H)
check_include_files(inttypes.h HAVE_INTTYPES_H)
check_include_files(stdbool.h HAVE_STDBOOL_H)
check_include_files(limits.h HAVE_LIMITS_H)

check_include_files(stddef.h HAVE_STDDEF_H)
check_include_files(ctype.h HAVE_CTYPE_H)
check_include_files(unistd.h HAVE_UNISTD_H)
check_include_files(stdarg.h HAVE_STDARG_PROTOTYPES)
check_include_files(sys/tree.h HAVE_SYS_TREE)
Expand All @@ -47,15 +50,18 @@ check_c_compiler_flag(-fstack-protector-strong has_stack_protector)
set(LIBEVHTP_SOURCE_FILES
evhtp.c
numtoa.c
parser.c)
parser.c
log.c)

find_package(LibEvent REQUIRED)
list(APPEND LIBEVHTP_EXTERNAL_LIBS ${LIBEVENT_LIBRARIES})
list(APPEND LIBEVHTP_EXTERNAL_INCLUDES ${LIBEVENT_INCLUDE_DIRS})
list(APPEND package_deps LibEvent)

set(evhtp_dir_headers
"include/evhtp/evhtp.h"
"include/evhtp/parser.h"
"include/evhtp/assert.h")
"include/evhtp/log.h")

if(NOT EVHTP_DISABLE_SSL)
find_package(OpenSSL)
Expand All @@ -81,7 +87,8 @@ if(NOT EVHTP_DISABLE_REGEX)
find_package(Oniguruma)
if(ONIGURUMA_FOUND)
list(APPEND LIBEVHTP_EXTERNAL_LIBS ${ONIGURUMA_LIBRARIES})
list(APPEND package_deps Oniguruma)
list(APPEND LIBEVHTP_EXTERNAL_INCLUDES ${ONIGURUMA_INCLUDE_DIRS})
list(APPEND package_deps oniguruma)
else()
message(STATUS "${BoldRed}${CMAKE_BUILD_TYPE}ONIGURUMA NOT FOUND, DISABLING REGEX SUPPORT${ColourReset}")
set(EVHTP_DISABLE_REGEX ON)
Expand All @@ -104,6 +111,7 @@ endif()

add_library(evhtp ${LIBEVHTP_SOURCE_FILES})
target_link_libraries(evhtp PUBLIC ${LIBEVHTP_EXTERNAL_LIBS})
target_include_directories(evhtp PUBLIC ${LIBEVHTP_EXTERNAL_INCLUDES})

target_compile_definitions(evhtp PUBLIC "PROJECT_VERSION=${PROJECT_VERSION}")
if(has_stack_protector)
Expand Down
16 changes: 16 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
v1.2.17-beta
o Fix cmake include dirs (b7df3fc Piotr Padlewski)
o Change case of oniguruma in package_deps (b8ff92b Piotr Padlewski)
o fix memory leak in evthr_free when compiled with EVHTP_THR_SHARED_PIPE (919e4ea t00416110)
o cleanups / added uncrustify configurations (d008f21 Nathan French)
o Feature/better thread distribution (#102) (1454b6c Nathan French)
o add content-length for client requests (fb1e594 Nathan French)
o add client buffer_out after headers (5c8640c Nathan French)
o added changelog release script (845c193 Nathan French)
o [unescape_string] do not set *out to NULL (reported by @ripulpatel) (606f3e3 Nathan French)
o http access-log API (a0a8641 Nathan French)
o fixed missing exported symbols for header_(new|find) (ec75536 Nathan French)
o access-log API finalization / cleanups and overhauls (5f74f32 Nathan French)
o evhtp_unescape_string tests (ae731f1 Nathan French)
o Added test of a on_connection_finished hook (5a17742 Nathan French)

v1.2.17-alpha
o use evhtp_safe_free everywhere (cbafca7 Nathan French)
o free fix for test_query.c (77f20e6 Nathan French)
Expand Down
96 changes: 96 additions & 0 deletions dist/make_changelog.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
#!/usr/bin/env bash

old_tag=
new_tag=
regen=0

usage() {
cat << EOF
Usage: $0 [opts]
OPTS:
-h This help text
-F Regenerate the entire ChangeLog
-o Old git tag (default action is to automagically find your last tag)
-n New git tag (default action is to use git-flow release to find your new tag name)
EOF
}

while getopts "hFo:n:" OPTION
do
case $OPTION in
h)
usage
exit 0
;;
F)
regen=1
;;
o)
old_tag=$OPTARG
;;
n)
new_tag=$OPTARG
;;
?)
echo "No such option $OPTARG"
usage
exit -1
;;
esac
done

function generate_changelog() {
old=$1
new=$2

git --no-pager log --no-merges --reverse --pretty='format: o %s (%h %an)' $old..$new
echo ""
echo ""
}

use_head=0

if [ -z $old_tag ]
then
l_sha=`git rev-list --tags --max-count=1..HEAD`
old_tag=`git describe --tags $l_sha`
fi

if [ -z $new_tag ]
then
new_tag=`git flow release | awk '{print $2}'`
use_head=1
fi

echo v$new_tag

if [ $use_head -eq 1 ]
then
generate_changelog $old_tag HEAD
fi

if [ $regen -eq 1 ]
then
tags=()

for tag in `git for-each-ref --sort='*authordate' --format='%(refname)' refs/tags | awk -F/ '{print $3}'` ; do
tags+=("$tag")
done

last_tag=

for ((i=${#tags[@]-1}; i>=0; i--)); do
if [ -z $last_tag ]
then
last_tag=${tags[$i]}
continue
fi

echo v${tags[$i]}

generate_changelog ${tags[$i]} $last_tag

last_tag=${tags[$i]}
done
fi
Loading

0 comments on commit c42cbe3

Please sign in to comment.