Commit 187ff4c4 authored by Adrien Oliva's avatar Adrien Oliva

Initialize repository

parents
Pipeline #208 failed with stages
in 43 seconds
# http://www.gnu.org/software/automake
Makefile.in
Makefile
# http://www.gnu.org/software/autoconf
/autom4te.cache
/autoscan.log
/autoscan-*.log
/aclocal.m4
/compile
config.h.in
/configure
/configure.scan
/config.guess
/config.log
/config.status
/config.sub
/configure.ac
libtool
ltmain.sh
/depcomp
/install-sh
/missing
/stamp-h1
/ar-lib
.deps/
.libs/
.dirstamp
config.h
stamp-h1
*.log
*.trs
test-driver
*.m4
INSTALL
# Object files
*.o
*.ko
*.obj
*.elf
# Precompiled headers
*.gch
*.pch
# Libraries
*.lib
*.a
*.la
*.lo
# Shared objects (inc. Windows DLLs)
*.dll
*.so
*.so.*
*.dylib
# Executables
*.exe
*.out
*.app
*.i*86
*.x86_64
*.hex
*.x
*.xtest
# Debug files
*.dSYM/
*.su
# Coverage files
*.gcda
*.gcno
coverage-report*
# Compiled object files
*.slo
# Editor buffer
*~
*.sw?
# Distribution package archive
*.tar
*.tar
*.tar.*
# CppUTest xml report
cpputest*.xml
# Build folder
build/
# Doxygen
doc/html
doc/Doxyfile
doc/document.h
# Pkgconfig information file
*.pc
before_script:
- ./autogen.sh
stages:
- build
- test
- deploy
build:
stage: build
script:
- ./configure
- make
check:
stage: test
script:
- ./configure --enable-coverage
- make coverage | tail -10
distribute:
stage: deploy
script:
- ./configure
- make dist
artifacts:
paths:
- libyaplog-*.tar.gz
expire_in: 1 week
except:
- tags
distribute-release:
stage: deploy
script:
- ./configure
- make dist
artifacts:
paths:
- libyaplog-*.tar.gz
only:
- tags
1 Adrien Oliva <olivaa+gitlab@yapbreak.fr>
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2018 Adrien Oliva <olivaa+gitlab@yapbreak.fr>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.
ChangeLog.md
\ No newline at end of file
# ChangeLog
ACLOCAL_AMFLAGS = -I m4
include Makefile.common
SOURCE_DIR = src
if CPPUTEST
SOURCE_DIR += utests
endif
SUBDIRS = $(SOURCE_DIR)
EXTRA_DIST = configure.ac
ALLPHONY = coverage doc
doc:
@(cd doc && $(MAKE) $@)
if COVERAGE
if LCOV
lcov-coverage-clean:
lcov --compat-libtool --directory "$(top_srcdir)/src" --zerocounters --output-file "coverage-report.info"
lcov-coverage-filter:
lcov --rc lcov_branch_coverage=1 --compat-libtool --directory "$$(readlink -f "$(top_builddir)/")" --capture --output-file "coverage-report.info"
lcov --rc lcov_branch_coverage=1 --extract "coverage-report.info" "$$(readlink -f "$(top_srcdir)")/*" --output-file "coverage-report2.info"
lcov --rc lcov_branch_coverage=1 --remove "coverage-report2.info" "*utests*" "*demo*" --output-file "coverage-report.info"
if GENHTML
GENHTML_EXTRA = --rc lcov_branch_coverage=1 --highlight --legend --demangle-cpp
if PERLGD
GENHTML_EXTRA += --frames
endif # PERLGD
genhtml-coverage-report:
genhtml $(GENHTML_EXTRA) --output-directory "coverage-report" --prefix "$$(readlink -f $(top_srcdir))" "coverage-report.info"
else # GENHTML
genhtml-coverage-report:
@(echo "Lcov suite is not completely installed. Please be sure to have genhtml to get beautiful coverage report")
endif # GENHTML
else # LCOV
lcov-coverage-clean:
lcov-coverage-filter:
genhtml-coverage-report:
endif # LCOV
if LCOV_COBERTURA
lcov-cobertura-report:
lcov_cobertura "coverage-report.info" -o "coverage-report.xml"
gcovr-coverage-report:
else # LCOV_COBERTURA
lcov-cobertura-report:
if GCOVR
gcovr-coverage-report:
gcovr -r . --exclude-unreachable-branches --exclude-directories="utests" --xml -o "coverage-report.xml"
else # GCOVR
gcovr-coverage-report:
endif # GCOVR
endif # LCOV_COBERTURA
coverage-clean: lcov-coverage-clean
coverage-report: lcov-coverage-filter genhtml-coverage-report lcov-cobertura-report gcovr-coverage-report
coverage: coverage-clean check coverage-report
ALLPHONY += coverage-clean
ALLPHONY += coverage-report
ALLPHONY += lcov-coverage-clean
ALLPHONY += lcov-coverage-filter
ALLPHONY += genhtml-coverage-report
ALLPHONY += gcovr-coverage-report
ALLPHONY += lcov-cobertura-report
else # COVERAGE
coverage:
@(echo "Coverage support is disabled. Re-run configure with --enable-coverage switch.")
endif # COVERAGE
CLEANFILES = "coverage-report.info" "coverage-report2.info" "coverage-report" "coverage-report.xml"
clean-local:
@rm -rf $(CLEANFILES)
.PHONY: $(ALLPHONY)
AM_CFLAGS = -std=c11 -Wall -Wextra ${extra_CFLAGS}
AM_CXXFLAGS = -std=c++11 -Wall -Wextra ${extra_CXXFLAGS}
AM_LDFLAGS = ${extra_LDFLAGS}
AM_CFLAGS += -I$(top_srcdir)/src
AM_CFLAGS += -I$(top_builddir)/src
AM_CFLAGS += -include $(top_builddir)/src/config.h
AM_CXXFLAGS += -I$(top_srcdir)/src
AM_CXXFLAGS += -I$(top_builddir)/src
AM_CXXFLAGS += -include $(top_builddir)/src/config.h
AM_LDFLAGS += -L$(top_builddir)
NEWS.md
\ No newline at end of file
# NEWS
README.md
\ No newline at end of file
[![pipeline status](https://gitlab.yapbreak.fr/libraries/libyaplog/badges/master/pipeline.svg)](https://gitlab.yapbreak.fr/libraries/libyaplog/commits/master)
[![coverage report](https://gitlab.yapbreak.fr/libraries/libyaplog/badges/master/coverage.svg)](https://gitlab.yapbreak.fr/libraries/libyaplog/commits/master)
This library is released under the terms of WTF-PL:
```
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
Version 2, December 2004
Copyright (C) 2018 Adrien Oliva <olivaa+gitlab@yapbreak.fr>
Everyone is permitted to copy and distribute verbatim or modified
copies of this license document, and changing it is allowed as long
as the name is changed.
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
0. You just DO WHAT THE FUCK YOU WANT TO.
```
#!/bin/sh
git shortlog -sne > AUTHORS
./version.sh || exit 127
aclocal || exit 126
autoreconf --install --force --symlink || exit 125
echo "Now run ./configure && make && sudo make install"
AC_PREREQ([2.69])
AC_INIT()
AM_INIT_AUTOMAKE([-Wall -Werror])
AC_CONFIG_MACRO_DIR([m4])
AC_CONFIG_SRCDIR([src/yaplog.h])
AC_CONFIG_HEADERS([src/config.h])
AC_PREFIX_DEFAULT(/usr/local)
VERSION_CURRENT=___CURRENT___
VERSION_REVISION=___REVISION___
VERSION_AGE=___AGE___
AC_SUBST(VERSION_CURRENT)
AC_SUBST(VERSION_REVISION)
AC_SUBST(VERSION_AGE)
# Checks for programs
AC_PROG_CXX
AC_PROG_AWK
AC_PROG_CC
AC_PROG_CPP
AC_PROG_INSTALL
AC_PROG_LN_S
AC_PROG_MAKE_SET
AM_PROG_AR
LT_INIT
# Checks for libraries
extra_CFLAGS=""
extra_CXXFLAGS=""
extra_LDFLAGS=""
compiler_generic_flags=""
compiler_c_flags=""
compiler_cxx_flags=""
GCC_VERSION=""
GCC_VERSION_MAJOR=0
GCC_VERSION_MINOR=0
GCC_VERSION_PATCH=0
AS_IF([test "x$GCC" = "xyes"], [
GCC_VERSION="$($CC -dumpversion)"
GCC_VERSION_MAJOR=$(echo $GCC_VERSION | cut -d'.' -f1)
GCC_VERSION_MINOR=$(echo $GCC_VERSION | cut -d'.' -f2)
GCC_VERSION_PATCH=$(echo $GCC_VERSION | cut -d'.' -f3)
])
AS_IF([test $GCC_VERSION_MAJOR -ge 3], [
compiler_generic_flags+="-Wshadow "
compiler_generic_flags+="-Wformat=2 "
compiler_cxx_flags+="-Wold-style-cast "
])
AS_IF([test $GCC_VERSION_MAJOR -ge 4], [
AS_IF([test $GCC_VERSION_MAJOR -gt 4 -o $GCC_VERSION_MINOR -ge 3], [
compiler_generic_flags+="-Wlogical-op "
])
AS_IF([test $GCC_VERSION_MAJOR -gt 4 -o $GCC_VERSION_MINOR -ge 5], [
compiler_generic_flags+="-Wdouble-promotion "
compiler_c_flags+="-Wjump-misses-init "
])
AS_IF([test $GCC_VERSION_MAJOR -gt 4 -o $GCC_VERSION_MINOR -ge 8], [
compiler_cxx_flags+="-Wuseless-cast "
])
])
AS_IF([test $GCC_VERSION_MAJOR -ge 6], [
compiler_generic_flags+="-Wduplicated-cond "
compiler_generic_flags+="-Wnull-dereference "
])
AS_IF([test $GCC_VERSION_MAJOR -ge 7], [
compiler_generic_flags+="-Wduplicated-branches "
compiler_generic_flags+="-Wrestrict "
])
# Debug flags
AC_ARG_ENABLE(debug,
AS_HELP_STRING([--enable-debug],
[enable debugging [default: no]]),
[],
[enable_debug=no])
AM_CONDITIONAL(DEBUG, test "x${enable_debug}" = "xyes")
AM_COND_IF(DEBUG,
[AC_DEFINE(__DEBUG__, 1, [Define to 0 if this is a release build])
extra_CFLAGS+="-Werror -g $compiler_generic_flags $compiler_c_flags"
extra_CXXFLAGS+="-Werror -g $compiler_generic_flags $compiler_cxx_flags"
]
)
# Coverage flags
AC_ARG_ENABLE([coverage],
AS_HELP_STRING([--enable-coverage],
[enable coverage report while testing [default: no]]),
[],
[enable_coverage=no])
AS_IF([test "x$GCC" = "xyes"],
[AM_CONDITIONAL(COVERAGE, test "x${enable_coverage}" = "xyes")
AM_COND_IF(COVERAGE,
[extra_CFLAGS+="--coverage "
extra_CXXFLAGS+="--coverage "
extra_LDFLAGS+="-lgcov "
])
],
[AC_MSG_WARN([Coverage is currently not supported with a compiler other than GCC])]
)
# Profiling flags
AC_ARG_ENABLE([profile],
AS_HELP_STRING([--enable-profile],
[enable profiling functions while testing [default: no]]),
[],
[enable_profile=no])
AS_IF([test "x$GCC" = "xyes"],
[AM_CONDITIONAL(PROFILE, test "x${enable_profile}" = "xyes")
AM_COND_IF(PROFILE,
[extra_CFLAGS+="-pg "
extra_CXXFLAGS+="-pg "
])
],
[AC_MSG_WARN([Profiling is currently not supported with a compiler other than GCC])]
)
AC_SUBST([extra_CFLAGS])
AC_SUBST([extra_CXXFLAGS])
AC_SUBST([extra_LDFLAGS])
# Checks for header files
AC_CHECK_HEADERS([cstdint])
AC_CHECK_HEADERS([cstring])
AC_CHECK_HEADERS([cstdlib])
AC_CHECK_HEADERS([ctime])
AC_CHECK_HEADERS([thread])
# Checks for typedefs, structures, and compiler characteristics
AC_CHECK_HEADER_STDBOOL
AC_TYPE_SIZE_T
AC_TYPE_UINT64_T
AC_TYPE_UINT8_T
# Checks for library functions
#AC_FUNC_MALLOC
#AC_CHECK_FUNC([memcpy printf])
#AC_CHECK_FUNC([strerror_r])
# Check if test utility are present
PKG_CHECK_MODULES([CPPUTEST], [cpputest], [have_cpputest=yes], [have_cpputest=no])
AM_CONDITIONAL([CPPUTEST], [test "x${have_cpputest}" = "xyes"])
AS_IF([test "x$have_cpputest" = "xno"],
[AC_MSG_WARN([Please install CppUTest package to get support of unit tests.])])
# Check coverage tools
AC_CHECK_PROG([gcovr], [gcovr], [yes])
AM_CONDITIONAL(GCOVR, [test "x${gcovr}" = "xyes"])
AC_CHECK_PROG([lcov_cobertura], [lcov_cobertura], [yes])
AM_CONDITIONAL(LCOV_COBERTURA, [test "x${lcov_cobertura}" = "xyes"])
AC_CHECK_PROG([lcov], [lcov], [yes])
AM_CONDITIONAL(LCOV, [test "x${lcov}" = "xyes"])
AC_CHECK_PROG([genhtml], [genhtml], [yes])
AM_CONDITIONAL(GENHTML, [test "x${genhtml}" = "xyes"])
AM_CONDITIONAL(PERLGD, [perldoc -l GD])
# Check doxygen installation
AC_CHECK_PROG([doxygen], [doxygen], [yes])
AM_CONDITIONAL(DOXYGEN, [test "x${doxygen}" = "xyes"])
# Generate files
AC_CONFIG_FILES([Makefile
utests/Makefile
utests/fixtures/Makefile
src/Makefile
src/yaplog.pc
doc/Makefile
doc/Doxyfile
doc/document.h
])
AM_SILENT_RULES([yes])
AC_OUTPUT
# vi:syntax=config
#!/bin/bash
if [ ! -x /usr/bin/cppcheck ]; then
echo "No cppcheck found"
exit 127
fi
output=plain
if [ -n "$1" ]; then
case "$1" in
"xml")
output=xml
shift
;;
"plain")
output=plain
shift
;;
esac
fi
declare -a OUTPUT_FLAGS
if [ "$output" == "xml" ]; then
OUTPUT_FLAGS=("--xml" "--xml-version=2")
fi
/usr/bin/cppcheck --enable=all --verbose --quiet --suppress=missingIncludeSystem --suppress=unusedFunction -I./src --inline-suppr "${OUTPUT_FLAGS[@]}" "$@" src/ demo/
DOXYFILE_ENCODING = UTF-8
PROJECT_NAME = @PACKAGE_NAME@
PROJECT_NUMBER = @PACKAGE_VERSION@
PROJECT_BRIEF = "Simple C++ logger"
#PROJECT_LOGO = @abs_top_srcdir@/doc/img/logo.png
OUTPUT_DIRECTORY = @abs_top_builddir@/doc
CREATE_SUBDIRS = YES
ALLOW_UNICODE_NAMES = YES
OUTPUT_LANGUAGE = English
BRIEF_MEMBER_DESC = YES
REPEAT_BRIEF = YES
ABBREVIATE_BRIEF = "The $name class" "The $name widget" "The $name file" is provides specifies contains represents a an the
ALWAYS_DETAILED_SEC = NO
INLINE_INHERITED_MEMB = NO
FULL_PATH_NAMES = NO
STRIP_FROM_PATH = @abs_top_srcdir@/src
STRIP_FROM_INC_PATH = @abs_top_srcdir@/src
SHORT_NAMES = NO
JAVADOC_AUTOBRIEF = NO
QT_AUTOBRIEF = NO
MULTILINE_CPP_IS_BRIEF = NO
INHERIT_DOCS = YES
SEPARATE_MEMBER_PAGES = NO
TAB_SIZE = 4
ALIASES =
TCL_SUBST =
OPTIMIZE_OUTPUT_FOR_C = YES
OPTIMIZE_OUTPUT_JAVA = NO
OPTIMIZE_FOR_FORTRAN = NO
OPTIMIZE_OUTPUT_VHDL = NO
EXTENSION_MAPPING =
MARKDOWN_SUPPORT = YES
TOC_INCLUDE_HEADINGS = 0
AUTOLINK_SUPPORT = YES
BUILTIN_STL_SUPPORT = YES
CPP_CLI_SUPPORT = NO
SIP_SUPPORT = NO
IDL_PROPERTY_SUPPORT = YES
DISTRIBUTE_GROUP_DOC = NO
GROUP_NESTED_COMPOUNDS = NO
SUBGROUPING = YES
INLINE_GROUPED_CLASSES = NO
INLINE_SIMPLE_STRUCTS = NO
TYPEDEF_HIDES_STRUCT = NO
LOOKUP_CACHE_SIZE = 0
#---------------------------------------------------------------------------
# Build related configuration options
#---------------------------------------------------------------------------
EXTRACT_ALL = NO
EXTRACT_PRIVATE = YES
EXTRACT_PACKAGE = YES
EXTRACT_STATIC = YES
EXTRACT_LOCAL_CLASSES = YES
EXTRACT_LOCAL_METHODS = YES
EXTRACT_ANON_NSPACES = YES
HIDE_UNDOC_MEMBERS = NO
HIDE_UNDOC_CLASSES = NO
HIDE_FRIEND_COMPOUNDS = NO
HIDE_IN_BODY_DOCS = NO
INTERNAL_DOCS = NO
CASE_SENSE_NAMES = NO
HIDE_SCOPE_NAMES = NO
HIDE_COMPOUND_REFERENCE= NO
SHOW_INCLUDE_FILES = YES
SHOW_GROUPED_MEMB_INC = YES
FORCE_LOCAL_INCLUDES = NO
INLINE_INFO = YES
SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = NO
SORT_MEMBERS_CTORS_1ST = NO
SORT_GROUP_NAMES = NO
SORT_BY_SCOPE_NAME = NO
STRICT_PROTO_MATCHING = YES
GENERATE_TODOLIST = YES
GENERATE_TESTLIST = YES
GENERATE_BUGLIST = YES
GENERATE_DEPRECATEDLIST= YES
ENABLED_SECTIONS =
MAX_INITIALIZER_LINES = 30
SHOW_USED_FILES = YES
SHOW_FILES = YES
SHOW_NAMESPACES = YES
FILE_VERSION_FILTER =
LAYOUT_FILE =
CITE_BIB_FILES =
#---------------------------------------------------------------------------
# Configuration options related to warning and progress messages
#---------------------------------------------------------------------------
QUIET = NO
WARNINGS = YES
WARN_IF_UNDOCUMENTED = YES
WARN_IF_DOC_ERROR = YES
WARN_NO_PARAMDOC = YES
WARN_AS_ERROR = YES
WARN_FORMAT = "$file:$line: $text"
WARN_LOGFILE =
#---------------------------------------------------------------------------
# Configuration options related to the input files
#---------------------------------------------------------------------------
INPUT = @abs_top_srcdir@/src @abs_top_srcdir@/doc
INPUT_ENCODING = UTF-8
FILE_PATTERNS = *.c *.cpp *.h
RECURSIVE = YES
EXCLUDE =
EXCLUDE_SYMLINKS = NO
EXCLUDE_PATTERNS =
EXCLUDE_SYMBOLS =
#EXAMPLE_PATH = @abs_top_srcdir@/sample
EXAMPLE_PATTERNS = *.c *.cpp *.h
EXAMPLE_RECURSIVE = YES
IMAGE_PATH = @abs_top_srcdir@/doc/img
INPUT_FILTER =
FILTER_PATTERNS =
FILTER_SOURCE_FILES = NO
FILTER_SOURCE_PATTERNS =
USE_MDFILE_AS_MAINPAGE =
#---------------------------------------------------------------------------
# Configuration options related to source browsing
#---------------------------------------------------------------------------
SOURCE_BROWSER = YES
INLINE_SOURCES = YES
STRIP_CODE_COMMENTS = YES
REFERENCED_BY_RELATION = YES
REFERENCES_RELATION = YES
REFERENCES_LINK_SOURCE = YES
SOURCE_TOOLTIPS = YES
USE_HTAGS = NO
VERBATIM_HEADERS = YES
#---------------------------------------------------------------------------
# Configuration options related to the alphabetical class index
#---------------------------------------------------------------------------
ALPHABETICAL_INDEX = YES
COLS_IN_ALPHA_INDEX = 5
IGNORE_PREFIX =
#---------------------------------------------------------------------------
# Configuration options related to the HTML output
#---------------------------------------------------------------------------
GENERATE_HTML = YES
HTML_OUTPUT = html
HTML_FILE_EXTENSION = .html
HTML_HEADER =
HTML_FOOTER =
HTML_STYLESHEET =
HTML_EXTRA_STYLESHEET =
HTML_EXTRA_FILES =
HTML_COLORSTYLE_HUE = 182
HTML_COLORSTYLE_SAT = 100
HTML_COLORSTYLE_GAMMA = 61
HTML_TIMESTAMP = NO
HTML_DYNAMIC_SECTIONS = YES
HTML_INDEX_NUM_ENTRIES = 100
GENERATE_DOCSET = NO
GENERATE_HTMLHELP = NO
GENERATE_CHI = NO
GENERATE_ECLIPSEHELP = NO
DISABLE_INDEX = NO
GENERATE_TREEVIEW = YES
ENUM_VALUES_PER_LINE = 4
TREEVIEW_WIDTH = 250
EXT_LINKS_IN_WINDOW = NO
FORMULA_FONTSIZE = 10
FORMULA_TRANSPARENT = YES
USE_MATHJAX = NO
MATHJAX_FORMAT = HTML-CSS
MATHJAX_RELPATH = http://cdn.mathjax.org/mathjax/latest
MATHJAX_EXTENSIONS =
MATHJAX_CODEFILE =