Commit 7bdbbd58 authored by Szarp Builder's avatar Szarp Builder

Merge current devel

parents a5e08bae 001cc9d3
......@@ -15,7 +15,6 @@ aclocal.m4
autom4te.cache
config.guess
config.h
config.h.in
config.log
config.status
config.sub
......@@ -34,3 +33,9 @@ current_tag
tags
test-driver
cfgdealer/cfgdealer_test
*.cmake
!cmake/Modules/*.cmake
CMakeCache.txt
CMakeFiles
install_manifest.txt
version.info
cmake_minimum_required(VERSION 3.2)
message(STATUS "Generating build using CMake ${CMAKE_VERSION}")
set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/cmake/Modules/")
# store short version to SZARP_VERSION, store long version to version.info (see below)
execute_process(COMMAND "${CMAKE_SOURCE_DIR}/script/version-info" -v "${CMAKE_SOURCE_DIR}/debian/changelog" OUTPUT_VARIABLE SZARP_VERSION)
add_custom_target( version.info ALL "${CMAKE_SOURCE_DIR}/script/version-info" "${CMAKE_SOURCE_DIR}/debian/changelog" > ${CMAKE_CURRENT_BINARY_DIR}/version.info )
set(PACKAGE_NAME "szarp") # /etc/PACKAGE_NAME/PACKAGE_NAME.cfg
project(${PACKAGE_NAME} LANGUAGES C CXX)
set(szarp_BINARY_STAGE_DIR ${szarp_BINARY_DIR}/stage CACHE INTERNAL "STAGE_DIR")
message(STATUS "Configuration types: ${CMAKE_CONFIGURATION_TYPES}")
string(TOUPPER "${CMAKE_BUILD_TYPE}" _build_type)
message(STATUS "CMAKE_C_FLAGS_${_build_type}: ${CMAKE_C_FLAGS_${_build_type}}")
message(STATUS "CMAKE_CXX_FLAGS_${_build_type}: ${CMAKE_CXX_FLAGS_${_build_type}}")
option(WITH_TESTS "Enable tests" ON)
if (${WITH_TESTS})
enable_testing()
endif()
option(BUILD_DOC "Enable documentation build" OFF)
include(GNUInstallDirs)
set(CMAKE_CXX_STANDARD 14)
set(CMAKE_CXX_STANDARD_REQUIRED ON)
set(CMAKE_CXX_EXTENSIONS OFF)
set(CMAKE_REQUIRED_LIBRARIES m)
set(CMAKE_REQUIRED_INCLUDES math.h)
set(Python_ADDITIONAL_VERSIONS 2.7)
set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/libs)
set(PACKAGE_BUGREPORT "devs@newterm.pl")
set(PACKAGE_URL "https://github.com/newterm/szarp")
set(PREFIX "/opt/szarp/")
set(VERSION ${SZARP_VERSION}) # required by some source files
set(CMAKE_POSITION_INDEPENDENT_CODE ON)
include(cmake/install_layout.cmake)
include(cmake/configure.cmake)
include(cmake/compiler.cmake)
include(cmake/packaging.cmake)
add_subdirectory(libSzarp)
add_subdirectory(libSzarp2)
add_subdirectory(python)
add_subdirectory(sender)
add_subdirectory(parcook)
add_subdirectory(cfgdealer)
add_subdirectory(isl)
add_subdirectory(meaner3)
add_subdirectory(iks)
add_subdirectory(extern)
add_subdirectory(wx)
add_subdirectory(utils)
add_subdirectory(unit_tests)
add_subdirectory(resources)
add_subdirectory(script)
add_subdirectory(qt4)
install(FILES version.info DESTINATION "${SZARP_SHAREDIR}" )
install(FILES libs/libpyszbase.so libs/libpysz4.so DESTINATION "${SZARP_LIBDIR}" )
......@@ -113,6 +113,3 @@ and one of the following:
# apt-get install szarp-server
# apt-get install szarp-terminal
# apt-get install szarp-viewer
# Makefile.am for SZARP
# Pawe Paucha <pawel@praterm.pl>
#
# $Id: Makefile.am 6583 2009-04-03 15:13:43Z pawel $
SUBDIRS = @SUBDIRS@
ACLOCAL_AMFLAGS = -I m4
MAINTAINERCLEANFILES = Makefile.in configure aclocal.m4 config.h.in \
depcomp install-sh missing mkinstalldirs ylwrap \
config.guess config.sub stamp-h.in py-compile
# Traditional SZARP target
cleanconfig: maintainer-clean
debian/rules clean
rm -rf doxy
# Create documentation
doc documentation:
${MAKE} -C resources/documentation/new doc
# Make version info
version:
@install -d $(DESTDIR)@prefix@/resources
@echo "Creating version info..."
@ @srcdir@/script/version-info @srcdir@/debian/changelog > $(DESTDIR)@prefix@/resources/version.info
install_scripts:
${MAKE} -C script install_scripts
logdir:
$(INSTALL) -d $(DESTDIR)@prefix@/logs
if !DEB_BUILD
install-data-hook: version logdir
else DEB_BUILD
install-data-hook: version logdir
endif
doxy:
cd @srcdir@ && doxygen
EXTRA_DIST = \
Doxyfile
.PHONY: doxy version
#!/bin/sh
# $Id$
echo "Running autoheader"
autoheader
echo "Running aclocal"
aclocal -I m4 -I /usr/share/aclocal
echo "Running libtoolize"
libtoolize
echo "Running automake"
automake -a -c
echo "Running autoconf"
autoconf
echo "Run ./configure to configure SZARP"
add_executable(cfgdealer
cfgdealer.cpp
cfgdealer.hpp
)
target_link_libraries(cfgdealer
PRIVATE
Szarp2
)
install(TARGETS cfgdealer
RUNTIME DESTINATION "${INSTALL_BINDIR}" DESTINATION bin)
add_executable(cfgdealer_test
cfgdealer_test.cpp
cfgdealer.hpp
)
target_link_libraries(cfgdealer_test
PRIVATE
Szarp2
)
# add_test(NAME cfgdealer_test.test COMMAND cfgdealer_test) # TODO : how to use this test?
# No subdirectories
SUBDIRS =
# Additional files for deleting on 'make maintainer-clean'
MAINTAINERCLEANFILES = Makefile.in
# Compilations flags
AM_CPPFLAGS = \
-I@srcdir@/../libSzarp/include \
-I@srcdir@/../libSzarp2/include
LIBSZARP=../libSzarp/libSzarp.la @BOOST_PROGRAM_OPTIONS_LIB@
LDADD = @PTHREAD_CFLAGS@ $(LIBSZARP2) $(LIBSZARP) \
@BOOST_SYSTEM_LIB@ @BOOST_FILESYSTEM_LIB@ \
@BOOST_PROGRAM_OPTIONS_LIB@ @ZMQ_LIBS@ @BOOST_LOCALE_LIB@
bin_PROGRAMS = cfgdealer cfgdealer_test
cfgdealer_SOURCES = \
cfgdealer.cpp
cfgdealer_test_SOURCES = \
cfgdealer_test.cpp
# Adapted from https://github.com/curl/curl under X/MIT license.
# Copyright (c) 1996 - 2019, Daniel Stenberg, <daniel@haxx.se>
#
# - Find c-ares
# Find the c-ares includes and library
# This module defines
# CARES_INCLUDE_DIR, where to find ares.h, etc.
# CARES_LIBRARIES, the libraries needed to use c-ares.
# CARES_FOUND, If false, do not try to use c-ares.
# also defined, but not for general use are
# CARES_LIBRARY, where to find the c-ares library.
find_path(CARES_INCLUDE_DIR ares.h
/usr/local/include
/usr/include
)
set(CARES_NAMES ${CARES_NAMES} cares)
find_library(CARES_LIBRARY
NAMES ${CARES_NAMES}
PATHS /usr/lib /usr/local/lib
)
if(CARES_LIBRARY AND CARES_INCLUDE_DIR)
set(CARES_LIBRARIES ${CARES_LIBRARY})
set(CARES_FOUND "YES")
else()
set(CARES_FOUND "NO")
endif()
if(CARES_FOUND)
if(NOT CARES_FIND_QUIETLY)
message(STATUS "Found c-ares: ${CARES_LIBRARIES}")
endif()
else()
if(CARES_FIND_REQUIRED)
message(FATAL_ERROR "Could not find c-ares library")
endif()
endif()
mark_as_advanced(
CARES_LIBRARY
CARES_INCLUDE_DIR
)
# Copyright (c) 2010 Fizians SAS. <http://www.fizians.com>
# This file is part of Rozofs.
#
# Rozofs is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published
# by the Free Software Foundation, version 2.
#
# Rozofs 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
# along with this program. If not, see
# <http://www.gnu.org/licenses/>.
# - Find crypt
# Find the native CRYPT includes and library
#
# CRYPT_INCLUDE_DIR - where to find crypt.h, etc.
# CRYPT_LIBRARIES - List of libraries when using crypt.
# CRYPT_FOUND - True if crypt found.
FIND_PATH(CRYPT_INCLUDE_DIR crypt.h
/usr/local/include/crypt
/usr/local/include
/usr/include/crypt
/usr/include
)
SET(CRYPT_NAMES crypt)
FIND_LIBRARY(CRYPT_LIBRARY
NAMES ${CRYPT_NAMES}
PATHS /usr/lib /usr/local/lib
)
IF(CRYPT_INCLUDE_DIR AND CRYPT_LIBRARY)
SET(CRYPT_FOUND TRUE)
SET(CRYPT_LIBRARIES ${CRYPT_LIBRARY} )
ELSE(CRYPT_INCLUDE_DIR AND CRYPT_LIBRARY)
SET(CRYPT_FOUND FALSE)
SET(CRYPT_LIBRARIES)
ENDIF(CRYPT_INCLUDE_DIR AND CRYPT_LIBRARY)
IF(NOT CRYPT_FOUND)
IF(CRYPT_FIND_REQUIRED)
MESSAGE(FATAL_ERROR "crypt library and headers required.")
ENDIF(CRYPT_FIND_REQUIRED)
ENDIF(NOT CRYPT_FOUND)
MARK_AS_ADVANCED(
CRYPT_LIBRARY
CRYPT_INCLUDE_DIR
)
#/*===========================================================================*\
#* *
#* OpenFlipper *
# * Copyright (c) 2001-2015, RWTH-Aachen University *
# * Department of Computer Graphics and Multimedia *
# * All rights reserved. *
# * www.openflipper.org *
# * *
# *---------------------------------------------------------------------------*
# * This file is part of OpenFlipper. *
# *---------------------------------------------------------------------------*
# * *
# * Redistribution and use in source and binary forms, with or without *
# * modification, are permitted provided that the following conditions *
# * are met: *
# * *
# * 1. Redistributions of source code must retain the above copyright notice, *
# * this list of conditions and the following disclaimer. *
# * *
# * 2. Redistributions in binary form must reproduce the above copyright *
# * notice, this list of conditions and the following disclaimer in the *
# * documentation and/or other materials provided with the distribution. *
# * *
# * 3. Neither the name of the copyright holder nor the names of its *
# * contributors may be used to endorse or promote products derived from *
# * this software without specific prior written permission. *
# * *
# * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS *
# * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED *
# * TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A *
# * PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER *
# * OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, *
# * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, *
# * PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR *
# * PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF *
# * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING *
# * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS *
# * SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *
#* *
#\*===========================================================================*/
# - Find FTGL
# Find the native FTGL headers and libraries.
#
# FTGL_INCLUDE_DIR - where to find FTGL.h, etc.
# FTGL_LIBRARIES - List of libraries when using FTGL.
# FTGL_FOUND - True if FTGL found.
GET_FILENAME_COMPONENT(module_file_path ${CMAKE_CURRENT_LIST_FILE} PATH )
# Look for the header file.
FIND_PATH(FTGL_INCLUDE_DIR NAMES FTGL/ftgl.h
PATHS /usr/include
/usr/local/include
../../External/include
"C:\\libs\\ftgl\\ftgl"