CMakeLists.txt 3.2 KB
Newer Older
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
# This file is part of the Castor project.
# See http://castor.web.cern.ch/castor
#
# Copyright (C) 2003  CERN
# 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; either version 2
# of the License, or (at your option) any later version.
# 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
#
#
# @author Castor Dev team, castor-dev@cern.ch
#
cmake_minimum_required (VERSION 2.6)

22
set (MEDIA_CHANGER_LIB_SRC_FILES
23
  AcsLibrarySlot.cpp
24
25
  LibrarySlot.cpp
  LibrarySlotParser.cpp
26
  ManualLibrarySlot.cpp
27
  MediaChangerFacade.cpp
28
  MmcProxy.cpp
29
  MmcProxyDummy.cpp
30
  MmcProxyLog.cpp
31
  MmcProxyNotSupported.cpp
32
  ScsiLibrarySlot.cpp
33
  TapeLibraryType.cpp)
34
add_library(castormediachanger ${MEDIA_CHANGER_LIB_SRC_FILES})
35

36
if (${COMPILE_SERVER} STREQUAL "1")
37

38
39
40
41
42
43
44
45
46
  ##############################################################################
  # Rules to build and install castor-tape-mediachanger-mount
  ##############################################################################
  set (MEDIA_CHANGER_MOUNT_SRC_FILES
    CmdLine.cpp
    CmdLineTool.cpp
    MountCmd.cpp
    MountCmdLine.cpp
    MountCmdMain.cpp)
47
48
  add_executable (castor-tape-mediachanger-mount
    ${MEDIA_CHANGER_MOUNT_SRC_FILES})
49
50
51
52
53
54
55
56
57
58
59
60
61
62
  set_target_properties (castor-tape-mediachanger-mount PROPERTIES
    COMPILE_FLAGS -I/usr/include/CDK
    COMPILE_DEFINITIONS LINUX)
  target_link_libraries (castor-tape-mediachanger-mount
    castorcommon
    castorlegacymsg
    castorlog
    castormediachanger
    castormessages
    castorutils
    ${STK_API_LIB}
    ${STK_UTL_LIB}
    ${STK_IPC_LIB}
    ${STK_CL_LIB})
63
64
  install (TARGETS castor-tape-mediachanger-mount
    DESTINATION ${CASTOR_DEST_BIN_DIR})
65
  CastorInstallExeManPage(castor-tape-mediachanger-mount)
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95

  ##############################################################################
  # Rules to build and install castor-tape-mediachanger-dismount
  ##############################################################################
  set (MEDIA_CHANGER_DISMOUNT_SRC_FILES
    CmdLine.cpp
    CmdLineTool.cpp
    DismountCmd.cpp
    DismountCmdLine.cpp
    DismountCmdMain.cpp)
  add_executable (castor-tape-mediachanger-dismount
    ${MEDIA_CHANGER_DISMOUNT_SRC_FILES})
  set_target_properties (castor-tape-mediachanger-dismount PROPERTIES
    COMPILE_FLAGS -I/usr/include/CDK
    COMPILE_DEFINITIONS LINUX)
  target_link_libraries (castor-tape-mediachanger-dismount
    castorcommon
    castorlegacymsg
    castorlog
    castormediachanger
    castormessages
    castorutils
    ${STK_API_LIB}
    ${STK_UTL_LIB}
    ${STK_IPC_LIB}
    ${STK_CL_LIB})
  install (TARGETS castor-tape-mediachanger-dismount
    DESTINATION ${CASTOR_DEST_BIN_DIR})
  CastorInstallExeManPage(castor-tape-mediachanger-dismount)

96
endif (${COMPILE_SERVER} STREQUAL "1")