summaryrefslogtreecommitdiffstats
path: root/eurephiadm/CMakeLists.txt
blob: 1fb2445c562e73eb5be4590fad843ae249881ed2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
#  cmake rules for eurephia - eurephiadm, console admin utility
#
#  GPLv2 only - Copyright (C) 2008-2009
#               David Sommerseth <dazo@users.sourceforge.net>
#
#  This program 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
#  of the License.
#
#  This program 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, write to the Free Software
#  Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
#
PROJECT(eurephiadm C)
cmake_minimum_required(VERSION 2.6)

# Compiler settings
INCLUDE_DIRECTORIES(../common ../database)

# eurephiadm parameters
SET(EUREPHIADM_XSLT_PATH "${XSLTROOT}/eurephiadm/" CACHE STRING "Path for eurephiadm XSLT templates")
ADD_DEFINITIONS(-DEUREPHIADM_XSLT_PATH="${EUREPHIADM_XSLT_PATH}")

IF(FIREWALL)
        ADD_DEFINITIONS(-DFIREWALL)
ENDIF(FIREWALL)

# Build rules for eurephiadm
ADD_EXECUTABLE(eurephiadm
        eurephiadm.c
        argparser.c
        get_console_input.c
        client_config.c
        client_context.c
        client_session.c
        parse_certificate_files.c
        xsltparser.c
        commands/users.c
        commands/lastlog.c
        commands/attempts.c
        commands/blacklist.c
        commands/certificates.c
        commands/usercerts.c
        commands/adminaccess.c
        commands/edit_config.c
        commands/fwprofiles.c
        ../common/eurephiadb_session_common.c
)
# Link in the following dynamic libraries with eurephiadm.
# ${EXTRA_LIBS} contains libxml2, libxslt and openssl library names
TARGET_LINK_LIBRARIES(eurephiadm dl crypto common ${EXTRA_LIBS})

# Install rules for eurephiadm
INSTALL(TARGETS eurephiadm RUNTIME DESTINATION ${BINDIR})

# Also run the rules for the XSLT templates eurephiadm needs
SUBDIRS(../xslt/eurephiadm)