Commit f26c489d authored by Luker's avatar Luker

added project

parent 8c918bb5
......@@ -4,9 +4,6 @@
[submodule "external/debug_assert"]
path = external/debug_assert
url = https://github.com/foonathan/debug_assert.git
[submodule "external/gsl"]
path = external/gsl
url = https://github.com/Microsoft/GSL.git
[submodule "external/libsodium"]
path = external/libsodium
url = https://github.com/jedisct1/libsodium.git
......@@ -14,3 +11,7 @@
[submodule "external/unbound"]
path = external/unbound
url = https://github.com/NLnetLabs/unbound.git
[submodule "external/gsl"]
path = external/gsl
url = https://github.com/djarek/GSL.git
branch = no_exception_support
This diff is collapsed.
#
# Copyright (c) 2017, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PATH(FENRIR_SODIUM_INCLUDE_DIR
NAMES sodium.h
PATH_SUFFIXES include/ include/sodium
PATHS
${SODIUM_ROOT}
$ENV{SODIUM_ROOT}
/usr/
/usr/local/
${CMAKE_CURRENT_SOURCE_DIR}/external/libsodium/src/libsodium
)
FIND_LIBRARY(FENRIR_SODIUM_LIB
NAMES sodium
PATH_SUFFIXES lib/
PATHS
${SODIUM_ROOT}
$ENV{SODIUM_ROOT}
/usr/
/usr/local/
)
IF(FENRIR_SODIUM_INCLUDE_DIR)
SET(FENRIR_SODIUM_FOUND TRUE)
ELSE(FENRIR_SODIUM_INCLUDE_DIR)
SET(FENRIR_SODIUM_FOUND FALSE)
ENDIF(FENRIR_SODIUM_INCLUDE_DIR)
IF(FENRIR_SODIUM_FOUND)
IF(BUILD_SODIUM)
# force our own lz4 libary
SET(FENRIR_SODIUM_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/external/libsodium/src/libsodium/include/)
ENDIF()
MESSAGE(STATUS "Found libsodium in ${FENRIR_SODIUM_INCLUDE_DIR}")
# we need both headers and library, or we use our own
IF(FENRIR_SODIUM_INCLUDE_DIR MATCHES "${CMAKE_CURRENT_SOURCE_DIR}/external/libsodium/src/libsodium/include" OR FENRIR_SODIUM_LIB MATCHES "FENRIR_SODIUM_LIB-NOTFOUND")
MESSAGE(WARNING "We will build our own libsodium(stable) library and statically link it.")
SET(BUILD_SODIUM TRUE)
ENDIF()
ELSE(FENRIR_SODIUM_FOUND)
IF(FENRIR_SODIUM_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"libsodium\" library."
" Please install the \"libsodium\" library"
" or at least run:\n"
" cd ${CMAKE_CURRENT_SOURCE_DIR}\n"
" git submodule init\n"
" git submodule update\n"
" so that we can build our own\n")
ENDIF(FENRIR_SODIUM_FIND_REQUIRED)
ENDIF(FENRIR_SODIUM_FOUND)
MARK_AS_ADVANCED(
FENRIR_SODIUM_INCLUDE_DIR
)
#
# Copyright (c) 2017, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
# NOTE: we need our own unbound 'cause the one in the distributions
# uses libevent. we use libev, and that clash breaks things
FIND_PATH(FENRIR_UNBOUND_INCLUDE_DIR
NAMES unbound.h
PATH_SUFFIXES include/
PATHS
${UNBOUND_ROOT}
$ENV{UNBOUND_ROOT}
/usr/
/usr/local/
${CMAKE_CURRENT_SOURCE_DIR}/external/unbound/libunbound/
)
FIND_LIBRARY(FENRIR_UNBOUND_LIB
NAMES unbound
PATH_SUFFIXES lib/
PATHS
${UNBOUND_ROOT}
$ENV{UNBOUND_ROOT}
/usr/
/usr/local/
)
IF(FENRIR_UNBOUND_INCLUDE_DIR)
SET(FENRIR_UNBOUND_FOUND TRUE)
ELSE(FENRIR_UNBOUND_INCLUDE_DIR)
SET(FENRIR_UNBOUND_FOUND FALSE)
ENDIF(FENRIR_UNBOUND_INCLUDE_DIR)
IF(FENRIR_UNBOUND_FOUND)
IF(BUILD_UNBOUND)
# force our own unbound libary
SET(FENRIR_UNBOUND_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/external/unbound/libunbound/)
ELSE()
execute_process(COMMAND "ldd ${FENRIR_UNBOUND_LIB}| grep event" OUTPUT_VARIABLE HAS_LIBEVENT)
string(REGEX MATCH ".*libevent.*" CMAKE_HAS_LIBEVENT "${HAS_LIBEVENT}")
IF (NOT ${CMAKE_HAS_LIBEVENT} MATCHES "")
# unbound was build with libevent. we use libev. clash and crash.
SET(UNBOUND_WAS_FOUND "true")
SET(FENRIR_UNBOUND_INCLUDE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/external/unbound/libunbound/)
ENDIF()
ENDIF()
MESSAGE(STATUS "Found libsodium in ${FENRIR_UNBOUND_INCLUDE_DIR}")
# we need both headers and library, or we use our own
IF(FENRIR_UNBOUND_INCLUDE_DIR MATCHES "${CMAKE_CURRENT_SOURCE_DIR}/external/unbound/libunbound" OR FENRIR_UNBOUND_LIB MATCHES "FENRIR_UNBOUND_LIB-NOTFOUND")
IF (${UNBOUND_WAS_FOUND} MATCHES "true")
MESSAGE(WARNING "We found libunbound, but it was build with libevent, therefore we need to rebuild unbound :(")
ELSE()
MESSAGE(WARNING "We will build our own libunbound(stable) library and statically link it.")
ENDIF()
SET(BUILD_UNBOUND TRUE)
ENDIF()
ELSE(FENRIR_UNBOUND_FOUND)
IF(FENRIR_UNBOUND_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"libunbound\" library."
" Please install the \"libunbound\" library"
" or at least run:\n"
" cd ${CMAKE_CURRENT_SOURCE_DIR}\n"
" git submodule init\n"
" git submodule update\n"
" so that we can build our own\n")
ENDIF(FENRIR_UNBOUND_FIND_REQUIRED)
ENDIF(FENRIR_UNBOUND_FOUND)
MARK_AS_ADVANCED(
FENRIR_UNBOUND_INCLUDE_DIR
)
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PATH(DEBUG_ASSERT_INCLUDE_DIR
NAMES debug_assert.hpp
PATH_SUFFIXES include/ debug_assert
PATHS
${DEBUG_ASSERT_ROOT}
$ENV{DEBUG_ASSERT_ROOT}
/usr/
/usr/local/
${PROJECT_SOURCE_DIR}/external/debug_assert
)
IF(DEBUG_ASSERT_INCLUDE_DIR)
SET(DEBUG_ASSERT_FOUND TRUE)
ELSE(DEBUG_ASSERT_INCLUDE_DIR)
SET(DEBUG_ASSERT_FOUND FALSE)
ENDIF(DEBUG_ASSERT_INCLUDE_DIR)
IF(DEBUG_ASSERT_FOUND)
MESSAGE(STATUS "Found debug_assert in ${DEBUG_ASSERT_INCLUDE_DIR}")
ELSE(DEBUG_ASSERT_FOUND)
IF(DEBUG_ASSERT_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"debug_assert\" library. please run\n"
"\tgit submodule init\n"
"\tgit submodule update\n")
ENDIF(DEBUG_ASSERT_FIND_REQUIRED)
ENDIF(DEBUG_ASSERT_FOUND)
MARK_AS_ADVANCED(
DEBUG_ASSERT_INCLUDE_DIR
)
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PATH(EV_INCLUDE_DIR
NAMES ev.h
PATH_SUFFIXES include/
PATHS
${EV_ROOT}
$ENV{EV_ROOT}
/usr/
)
IF(EV_INCLUDE_DIR)
SET(EV_FOUND TRUE)
ELSE(EV_INCLUDE_DIR)
SET(EV_FOUND FALSE)
ENDIF(EV_INCLUDE_DIR)
FIND_LIBRARY(EV_LIB
NAMES ev
PATH_SUFFIXES lib/
PATHS
${EV_ROOT}
$ENV{EV_ROOT}
/usr/
/usr/local/
)
IF(EV_FOUND)
MESSAGE(STATUS "Found libev in ${EV_INCLUDE_DIR}")
ELSE(EV_FOUND)
IF(EV_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"libev\"")
ENDIF(EV_FIND_REQUIRED)
ENDIF(EV_FOUND)
MARK_AS_ADVANCED(
EV_LIB
)
MARK_AS_ADVANCED(
EV_INCLUDE_DIR
)
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PROGRAM(GIT_EXECUTABLE git
PATHS
${PATH}
"C:/Program Files/Git/bin"
"C:/Program Files (x86)/Git/bin"
DOC "git command line client"
)
IF(GIT_EXECUTABLE)
SET(GIT_FOUND TRUE)
ELSE(GIT_EXECUTABLE)
SET(GIT_FOUND FALSE)
ENDIF(GIT_EXECUTABLE)
IF(GIT_FOUND)
MESSAGE(STATUS "Found git in ${GIT_EXECUTABLE}")
ELSE(GIT_FOUND)
IF(GIT_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"git\" command")
ENDIF(GIT_REQUIRED)
ENDIF(GIT_FOUND)
MARK_AS_ADVANCED(
GIT_EXECUTABLE
)
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PATH(GSL_INCLUDE_DIR
NAMES gsl/span
PATH_SUFFIXES include/ gsl
PATHS
${GSL_ROOT}
$ENV{GSL_ROOT}
/usr/
/usr/local/
${PROJECT_SOURCE_DIR}/external/gsl/include
)
IF(GSL_INCLUDE_DIR)
SET(GSL_FOUND TRUE)
ELSE(GSL_INCLUDE_DIR)
SET(GSL_FOUND FALSE)
ENDIF(GSL_INCLUDE_DIR)
IF(GSL_FOUND)
MESSAGE(STATUS "Found gsl in ${GSL_INCLUDE_DIR}")
ELSE(GSL_FOUND)
IF(GSL_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"gsl\" library. please run\n"
"\tgit submodule init\n"
"\tgit submodule update\n")
ELSE()
add_definitions(-DGSL_TERMINATE_ON_CONTRACT_VIOLATION)
ENDIF(GSL_FIND_REQUIRED)
ENDIF(GSL_FOUND)
MARK_AS_ADVANCED(
GSL_INCLUDE_DIR
)
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PATH(TYPE_SAFE_INCLUDE_DIR
NAMES type_safe
PATH_SUFFIXES include/ type_safe
PATHS
${TYPE_SAFE_ROOT}
$ENV{TYPE_SAFE_ROOT}
/usr/
/usr/local/
${PROJECT_SOURCE_DIR}/external/type_safe/include
)
IF(TYPE_SAFE_INCLUDE_DIR)
SET(TYPE_SAFE_FOUND TRUE)
ELSE(TYPE_SAFE_INCLUDE_DIR)
SET(TYPE_SAFE_FOUND FALSE)
ENDIF(TYPE_SAFE_INCLUDE_DIR)
IF(TYPE_SAFE_FOUND)
MESSAGE(STATUS "Found type_safe in ${TYPE_SAFE_INCLUDE_DIR}")
ELSE(TYPE_SAFE_FOUND)
IF(TYPE_SAFE_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"type_safe\" library. please run\n"
"\tgit submodule init\n"
"\tgit submodule update\n")
ENDIF(TYPE_SAFE_FIND_REQUIRED)
ENDIF(TYPE_SAFE_FOUND)
MARK_AS_ADVANCED(
TYPE_SAFE_INCLUDE_DIR
)
#
# Copyright (c) 2017, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_LIBRARY(UBSAN_LIB
NAMES ubsan
PATH_SUFFIXES lib/
PATHS
${UBSAN_ROOT}
$ENV{UBSAN_ROOT}
/usr/
/usr/local/
)
IF(UBSAN_LIB)
SET(UBSAN_FOUND TRUE)
ELSE(UBSAN_LIB)
SET(UBSAN_FOUND FALSE)
ENDIF(UBSAN_LIB)
IF(UBSAN_FOUND)
MESSAGE(STATUS "Found UBSAN in ${UBSAN_LIB}")
ELSE(UBSAN_FOUND)
IF(UBSAN_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"UBSAN\" library")
ENDIF(UBSAN_FIND_REQUIRED)
ENDIF(UBSAN_FOUND)
MARK_AS_ADVANCED(
UBSAN_LIB
)
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
FIND_PATH(UNBOUND_INCLUDE_DIR
NAMES unbound.h
PATH_SUFFIXES include/
PATHS
${UNBOUND_ROOT}
$ENV{UNBOUND_ROOT}
/usr/
)
IF(UNBOUND_INCLUDE_DIR)
SET(UNBOUND_FOUND TRUE)
ELSE(UNBOUND_INCLUDE_DIR)
SET(UNBOUND_FOUND FALSE)
ENDIF(UNBOUND_INCLUDE_DIR)
IF(UNBOUND_FOUND)
MESSAGE(STATUS "Found libunbound in ${UNBOUND_INCLUDE_DIR}")
ELSE(UNBOUND_FOUND)
IF(UNBOUND_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "Could not find \"libunbound\"")
ENDIF(UNBOUND_FIND_REQUIRED)
ENDIF(UNBOUND_FOUND)
MARK_AS_ADVANCED(
UNBOUND_INCLUDE_DIR
)
This diff is collapsed.
This diff is collapsed.
#
# Copyright (c) 2015, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of libFenrir.
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
#
# Now we try to guess the architecture... this will be fun... sigh..
# list of linux architectures (might be old, not all will be supported):
# i386 i686 x86_64 ia64 alpha amd64
# arm armeb armel hppa m32r m68k mips mipsel
# powerpc ppc64 s390 s390x sh3 sh3eb sh4 sh4eb sparc
SET(ARCH "X86_64" CACHE STRING "Processor architecture") # defult, most common
SET_PROPERTY(CACHE ARCH PROPERTY STRINGS X86_64 X86 ARM)
IF(ARCH)
# you provided us the right architecture? good ^^
ELSE()
#we need to guess it somehow...
IF(WIN32)
SET(ARCH "X86_64")
ENDIF()
IF(APPLE)
EXECUTE_PROCESS(COMMAND uname -m COMMAND tr -d '\n' OUTPUT_VARIABLE ARCH )
ENDIF()
IF(UNIX)
EXECUTE_PROCESS(COMMAND uname -m COMMAND tr -d '\n' OUTPUT_VARIABLE ARCH )
IF(${ARCH} STREQUAL "x86_64" OR ${ARCH} STREQUAL "amd64" OR ${ARCH} STREQUAL "ia64")
SET(ARCH, "X86_64")
ELSE()
IF(${ARCH} STREQUAL "x86" OR ${ARCH} STREQUAL "i686")
SET(ARCH, "X86")
ELSE()
IF(${ARCH} STREQUAL "arm" OR ${ARCH} STREQUAL "armeb" OR ${ARCH} STREQUAL "armel")
SET(ARCH, "ARM")
ELSE()
ENDIF()
ENDIF()
ENDIF()
ENDIF()
ENDIF()
#
# Copyright (c) 2016-2017, Luca Fulchir<luca@fulchir.it>, All rights reserved.
#
# This file is part of "libFenrir".
#
# libFenrir is free software: you can redistribute it and/or modify
# it under the terms of the GNU Lesser General Public License as
# published by the Free Software Foundation, either version 3
# of the License, or (at your option) any later version.
#
# libFenrir is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# and a copy of the GNU Lesser General Public License
# along with libFenrir. If not, see <http://www.gnu.org/licenses/>.
PROJECT(libFenrir_Doc)
CMAKE_MINIMUM_REQUIRED(VERSION 2.8)
INCLUDE(../cmake/UseLATEX.cmake)
IF (LATEX_COMPILER AND PDFLATEX_COMPILER AND MAKEINDEX_COMPILER)
ADD_LATEX_DOCUMENT(libFenrir.tex
INPUTS GNU_FDL.tex
USE_INDEX
MANGLE_TARGET_NAMES
NO_DEFAULT
)
ADD_CUSTOM_TARGET(docs DEPENDS libFenrir_pdf)
ELSE()
ADD_CUSTOM_TARGET(docs)
ENDIF()
INSTALL(FILES ${CMAKE_BINARY_DIR}/doc/libFenrir.pdf DESTINATION share/doc/ OPTIONAL)
This diff is collapsed.
% Copyright (C) 2016-2017, Luca Fulchir<luca@fulchir.it>
% Permission is granted to copy, distribute and/or modify this document
% under the terms of the GNU Free Documentation License, Version 1.3
% or any later version published by the Free Software Foundation;
% with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
% A copy of the license is included in the section entitled "GNU
% Free Documentation License".
\documentclass[11pt,a4paper]{refart}
\usepackage[utf8]{inputenc}
\usepackage{hyperref}
\usepackage{makeidx}
\usepackage{verbatimbox}
\usepackage{listings}
\usepackage{color}
\definecolor{mygreen}{rgb}{0,0.6,0}
\definecolor{mygray}{rgb}{0.5,0.5,0.5}
\definecolor{mymauve}{rgb}{0.58,0,0.82}
\lstset{ %
backgroundcolor=\color{white}, % choose the background color; you must add \usepackage{color} or \usepackage{xcolor}
basicstyle=\footnotesize, % the size of the fonts that are used for the code
breakatwhitespace=false, % sets if automatic breaks should only happen at whitespace
breaklines=true, % sets automatic line breaking
captionpos=b, % sets the caption-position to bottom
commentstyle=\color{mygreen}, % comment style
deletekeywords={...}, % if you want to delete keywords from the given language
escapeinside={\%*}{*)}, % if you want to add LaTeX within your code
extendedchars=true, % lets you use non-ASCII characters; for 8-bits encodings only, does not work with UTF-8
frame=single, % adds a frame around the code
keepspaces=true, % keeps spaces in text, useful for keeping indentation of code (possibly needs columns=flexible)
keywordstyle=\color{blue}, % keyword style
language=C, % the language of the code
%otherkeywords={*,...}, % if you want to add more keywords to the set
%numbers=left, % where to put the line-numbers; possible values are (none, left, right)
%numbersep=5pt, % how far the line-numbers are from the code
%numberstyle=\tiny\color{mygray}, % the style that is used for the line-numbers
rulecolor=\color{black}, % if not set, the frame-color may be changed on line-breaks within not-black text (e.g. comments (green here))
showspaces=false, % show spaces everywhere adding particular underscores; it overrides 'showstringspaces'
showstringspaces=false, % underline spaces within strings only
showtabs=false, % show tabs within strings adding particular underscores
stepnumber=2, % the step between two line-numbers. If it's 1, each line will be numbered
stringstyle=\color{mymauve}, % string literal style
tabsize=4, % sets default tabsize to 2 spaces
title=\lstname % show the filename of files included with \lstinputlisting; also try caption instead of title
}
\title{Using libFenrir library}