From cc68a037f04f2326cd3eb8b0d98dd5dd1622ab9e Mon Sep 17 00:00:00 2001 From: Marcel Loose <loose@astron.nl> Date: Thu, 9 Jul 2009 14:03:15 +0000 Subject: [PATCH] Bug 1310: Several small fixes. Output of CMake build and Autotools build of MAC is now almost identical --- MAC/APL/CMakeLists.txt | 24 ++++----- MAC/APL/PIC/CMakeLists.txt | 4 +- MAC/APL/PIC/RSP_Driver/test/CMakeLists.txt | 9 ++++ MAC/CMakeLists.txt | 6 ++- MAC/Deployment/CMakeLists.txt | 50 ++++++++++++++++++ MAC/Deployment/data/CMakeLists.txt | 23 +++++++++ MAC/Deployment/data/PVSS/CMakeLists.txt | 31 +++++++++++ .../data/StaticMetaData/CMakeLists.txt | 42 +++++++++++++++ MAC/Deployment/data/bin/CMakeLists.txt | 23 +++++++++ MAC/GCF/TM/src/CMakeLists.txt | 4 ++ MAC/MACIO/CMakeLists.txt | 1 + MAC/MACIO/autogen/CMakeLists.txt | 24 +++++++++ MAC/MACIO/src/CMakeLists.txt | 2 +- MAC/Navigator2/CMakeLists.txt | 51 +++++++++++++++++++ MAC/Navigator2/config/CMakeLists.txt | 26 ++++++++++ MAC/Navigator2/scripts/CMakeLists.txt | 29 +++++++++++ MAC/Navigator2/scripts/libs/CMakeLists.txt | 27 ++++++++++ 17 files changed, 359 insertions(+), 17 deletions(-) create mode 100644 MAC/Deployment/CMakeLists.txt create mode 100644 MAC/Deployment/data/CMakeLists.txt create mode 100644 MAC/Deployment/data/PVSS/CMakeLists.txt create mode 100644 MAC/Deployment/data/StaticMetaData/CMakeLists.txt create mode 100644 MAC/Deployment/data/bin/CMakeLists.txt create mode 100644 MAC/MACIO/autogen/CMakeLists.txt create mode 100644 MAC/Navigator2/CMakeLists.txt create mode 100644 MAC/Navigator2/config/CMakeLists.txt create mode 100644 MAC/Navigator2/scripts/CMakeLists.txt create mode 100644 MAC/Navigator2/scripts/libs/CMakeLists.txt diff --git a/MAC/APL/CMakeLists.txt b/MAC/APL/CMakeLists.txt index 91d1620079a..c4fb9cba8f3 100644 --- a/MAC/APL/CMakeLists.txt +++ b/MAC/APL/CMakeLists.txt @@ -41,18 +41,18 @@ execute_process(COMMAND ${CMAKE_COMMAND} -E make_directory ## --------------------------------------------------------------------------- ## Subdirectories ## --------------------------------------------------------------------------- -lofar_add_subdirectory(APLCommon) -lofar_add_subdirectory(RTCCommon) -lofar_add_subdirectory(RTDBCommon) -lofar_add_subdirectory(TestSuite) -lofar_add_subdirectory(CUDaemons) -lofar_add_subdirectory(CURTDBDaemons) -lofar_add_subdirectory(PIC) -lofar_add_subdirectory(PAC) -lofar_add_subdirectory(CEPCU) -lofar_add_subdirectory(MainCU) -lofar_add_subdirectory(StationCU) -lofar_add_subdirectory(TestCtlr) +lofar_add_subdirectory(APLCommon) # Common tasks and functions +lofar_add_subdirectory(RTCCommon) # Real Time Control functions +lofar_add_subdirectory(RTDBCommon) # RealTimeDataBase common software +lofar_add_subdirectory(TestSuite) # +lofar_add_subdirectory(CUDaemons) # Control Unit Daemons +lofar_add_subdirectory(CURTDBDaemons) # Control Unit RTDB Daemons +lofar_add_subdirectory(PIC) # Physical Instrument Components (?) +lofar_add_subdirectory(PAC) # ??? +lofar_add_subdirectory(CEPCU) # CEP-related MAC controllers +lofar_add_subdirectory(MainCU) # Main Control Unit +lofar_add_subdirectory(StationCU) # Station Control Unit software +lofar_add_subdirectory(TestCtlr) # Testprograms for MAC controllers ## --------------------------------------------------------------------------- ## Generate configuration header file. diff --git a/MAC/APL/PIC/CMakeLists.txt b/MAC/APL/PIC/CMakeLists.txt index 26db5e3327c..2fb32e9923b 100644 --- a/MAC/APL/PIC/CMakeLists.txt +++ b/MAC/APL/PIC/CMakeLists.txt @@ -36,8 +36,8 @@ include(LofarGeneral) ## --------------------------------------------------------------------------- lofar_add_subdirectory(RSP_Protocol) lofar_add_subdirectory(TBB_Protocol) -lofar_add_subdirectory(RSPDriver) -lofar_add_subdirectory(TBBDriver) +lofar_add_subdirectory(RSP_Driver) +lofar_add_subdirectory(TBB_Driver) ## --------------------------------------------------------------------------- ## Generate configuration header file. diff --git a/MAC/APL/PIC/RSP_Driver/test/CMakeLists.txt b/MAC/APL/PIC/RSP_Driver/test/CMakeLists.txt index 6188ce90547..da4f5235025 100644 --- a/MAC/APL/PIC/RSP_Driver/test/CMakeLists.txt +++ b/MAC/APL/PIC/RSP_Driver/test/CMakeLists.txt @@ -38,3 +38,12 @@ lofar_add_sbin_program(RSPTest RSPTest.cc) install(PROGRAMS beamtest DESTINATION sbin) + +foreach(file RSPTest.conf EPAStub.conf EPAStub.log_prop) + configure_file( + ${CMAKE_CURRENT_SOURCE_DIR}/${file}.in + ${CMAKE_CURRENT_BINARY_DIR}/${file}) + install(FILES + ${CMAKE_CURRENT_BINARY_DIR}/${file} + DESTINATION etc) +endforeach(file) diff --git a/MAC/CMakeLists.txt b/MAC/CMakeLists.txt index fe22b5b7454..c92c61a5240 100644 --- a/MAC/CMakeLists.txt +++ b/MAC/CMakeLists.txt @@ -36,8 +36,10 @@ include(LofarGeneral) ## --------------------------------------------------------------------------- lofar_add_subdirectory(MACIO) # MAC I/O related functions lofar_add_subdirectory(GCF) # Generic Control Framework -lofar_add_subdirectory(APL) -#lofar_add_subdirectory(Deployment) +lofar_add_subdirectory(APL) # Application subdirectory +lofar_add_subdirectory(Deployment) # Deployment related functions +lofar_add_subdirectory(Navigator2) +lofar_add_subdirectory(Tools) ## --------------------------------------------------------------------------- ## Generate configuration header file. diff --git a/MAC/Deployment/CMakeLists.txt b/MAC/Deployment/CMakeLists.txt new file mode 100644 index 00000000000..2907565120e --- /dev/null +++ b/MAC/Deployment/CMakeLists.txt @@ -0,0 +1,50 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +cmake_minimum_required(VERSION 2.6) + +## --------------------------------------------------------------------------- +## Preamble: set compilers +## --------------------------------------------------------------------------- +include(LofarInit) + +## --------------------------------------------------------------------------- +## Project characteristics +## --------------------------------------------------------------------------- +project(Deployment) +include(LofarGeneral) + +include(LofarAddPackage) +lofar_add_package(${PROJECT_NAME} 0.1 DEPENDS Common ApplCommon OTDB) + +## --------------------------------------------------------------------------- +## External packages +## --------------------------------------------------------------------------- +include(LofarFindPackage) + +## --------------------------------------------------------------------------- +## Generate configuration header file. +## --------------------------------------------------------------------------- +include(LofarConfig) + +## --------------------------------------------------------------------------- +## Subdirectories +## --------------------------------------------------------------------------- +add_subdirectory(data) diff --git a/MAC/Deployment/data/CMakeLists.txt b/MAC/Deployment/data/CMakeLists.txt new file mode 100644 index 00000000000..10839128695 --- /dev/null +++ b/MAC/Deployment/data/CMakeLists.txt @@ -0,0 +1,23 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +#add_subdirectory(bin) +add_subdirectory(StaticMetaData) +add_subdirectory(PVSS) diff --git a/MAC/Deployment/data/PVSS/CMakeLists.txt b/MAC/Deployment/data/PVSS/CMakeLists.txt new file mode 100644 index 00000000000..858eb3b961a --- /dev/null +++ b/MAC/Deployment/data/PVSS/CMakeLists.txt @@ -0,0 +1,31 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +install(PROGRAMS + create_db_files + DESTINATION sbin) + +file(GLOB pvss_dp_data + PVSSDataPoints.base + *.dpdef + *.list) +install(FILES + ${pvss_dp_data} + DESTINATION pvss/dpdef) diff --git a/MAC/Deployment/data/StaticMetaData/CMakeLists.txt b/MAC/Deployment/data/StaticMetaData/CMakeLists.txt new file mode 100644 index 00000000000..48fc925ae1c --- /dev/null +++ b/MAC/Deployment/data/StaticMetaData/CMakeLists.txt @@ -0,0 +1,42 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +install(PROGRAMS + createFiles + DESTINATION sbin) + +# These files end up in ${prefix}/etc +file(GLOB sysconf_data *.conf) +install(FILES + ${sysconf_data} + DESTINATION etc) + +# These files end up in ${prefix}/etc/StaticMetaData +file(GLOB staticmeta_data + *.tmpl + *.test + *.dat + AntennaArrays/*.conf + CableDelays/*.conf + HBADeltas/*.conf) +install(FILES + ${staticmeta_data} + DESTINATION etc/StaticMetaData) + \ No newline at end of file diff --git a/MAC/Deployment/data/bin/CMakeLists.txt b/MAC/Deployment/data/bin/CMakeLists.txt new file mode 100644 index 00000000000..d218e8febf8 --- /dev/null +++ b/MAC/Deployment/data/bin/CMakeLists.txt @@ -0,0 +1,23 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +lofar_add_sbin_program(load_OTDB_comps load_OTDB_comps.cc) +lofar_add_sbin_program(load_PICtree load_PICtree.cc) +lofar_add_sbin_program(PVSS2SAS PVSS2SAS.cc) diff --git a/MAC/GCF/TM/src/CMakeLists.txt b/MAC/GCF/TM/src/CMakeLists.txt index 148317d724a..2bb2eb5df15 100644 --- a/MAC/GCF/TM/src/CMakeLists.txt +++ b/MAC/GCF/TM/src/CMakeLists.txt @@ -52,3 +52,7 @@ lofar_add_library(gcftm ServiceBroker/ServiceBrokerTask.cc) lofar_add_bin_program(versiongcftm versiongcftm.cc) + +install(FILES + mac.log_prop + DESTINATION etc) diff --git a/MAC/MACIO/CMakeLists.txt b/MAC/MACIO/CMakeLists.txt index 51b321dacf4..18001bb59ef 100644 --- a/MAC/MACIO/CMakeLists.txt +++ b/MAC/MACIO/CMakeLists.txt @@ -53,6 +53,7 @@ include(LofarConfig) ## --------------------------------------------------------------------------- ## Subdirectories ## --------------------------------------------------------------------------- +add_subdirectory(autogen) add_subdirectory(include/MACIO) add_subdirectory(src) add_subdirectory(test) diff --git a/MAC/MACIO/autogen/CMakeLists.txt b/MAC/MACIO/autogen/CMakeLists.txt new file mode 100644 index 00000000000..9b3f1e50fb4 --- /dev/null +++ b/MAC/MACIO/autogen/CMakeLists.txt @@ -0,0 +1,24 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +# Install the protocol template file +install(FILES + protocol.tpl + DESTINATION share/MACIO) diff --git a/MAC/MACIO/src/CMakeLists.txt b/MAC/MACIO/src/CMakeLists.txt index caa0d55d26d..ebbbe3313b2 100644 --- a/MAC/MACIO/src/CMakeLists.txt +++ b/MAC/MACIO/src/CMakeLists.txt @@ -43,4 +43,4 @@ lofar_add_library(macio ## --------------------------------------------------------------------------- ## Add executables to be generated ## --------------------------------------------------------------------------- -lofar_add_executable(versionmacio versionmacio.cc) +lofar_add_bin_program(versionmacio versionmacio.cc) diff --git a/MAC/Navigator2/CMakeLists.txt b/MAC/Navigator2/CMakeLists.txt new file mode 100644 index 00000000000..c59ee02ee21 --- /dev/null +++ b/MAC/Navigator2/CMakeLists.txt @@ -0,0 +1,51 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +cmake_minimum_required(VERSION 2.6) + +## --------------------------------------------------------------------------- +## Preamble: set compilers +## --------------------------------------------------------------------------- +include(LofarInit) + +## --------------------------------------------------------------------------- +## Project characteristics +## --------------------------------------------------------------------------- +project(Navigator2) +include(LofarGeneral) + +include(LofarAddPackage) +lofar_add_package(${PROJECT_NAME} 1.0) + +## --------------------------------------------------------------------------- +## External packages +## --------------------------------------------------------------------------- +include(LofarFindPackage) + +## --------------------------------------------------------------------------- +## Generate configuration header file. +## --------------------------------------------------------------------------- +include(LofarConfig) + +## --------------------------------------------------------------------------- +## Subdirectories +## --------------------------------------------------------------------------- +add_subdirectory(config) +add_subdirectory(scripts) diff --git a/MAC/Navigator2/config/CMakeLists.txt b/MAC/Navigator2/config/CMakeLists.txt new file mode 100644 index 00000000000..943c0859be5 --- /dev/null +++ b/MAC/Navigator2/config/CMakeLists.txt @@ -0,0 +1,26 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +install(FILES + config.maincu + config.station + progs.maincu + progs.station + DESTINATION pvss/config) diff --git a/MAC/Navigator2/scripts/CMakeLists.txt b/MAC/Navigator2/scripts/CMakeLists.txt new file mode 100644 index 00000000000..b214e230ec5 --- /dev/null +++ b/MAC/Navigator2/scripts/CMakeLists.txt @@ -0,0 +1,29 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +add_subdirectory(libs) + +install(FILES + claim.ctl + monitorAlarms.ctl + monitorStateChanges.ctl + monitorStateReset.ctl + readStationConfigs.ctl + DESTINATION pvss/scripts) diff --git a/MAC/Navigator2/scripts/libs/CMakeLists.txt b/MAC/Navigator2/scripts/libs/CMakeLists.txt new file mode 100644 index 00000000000..7852a23bafe --- /dev/null +++ b/MAC/Navigator2/scripts/libs/CMakeLists.txt @@ -0,0 +1,27 @@ +# $Id$ +# +# Copyright (C) 2008-2009 +# ASTRON (Netherlands Foundation for Research in Astronomy) +# P.O.Box 2, 7990 AA Dwingeloo, The Netherlands, seg@astron.nl +# +# 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 + +install(FILES + GCFAlarm.ctl + GCFCommon.ctl + GCFCWD.ctl + GCFLogging.ctl + navFunct.ctl + DESTINATION pvss/scripts/libs) -- GitLab