WSL/SLF GitLab Repository

Commit 88688955 authored by Mathias Bavay's avatar Mathias Bavay
Browse files

Updated/improved some documentation for SNIO and the min/max/minmax filters....

Updated/improved some documentation for SNIO and the min/max/minmax filters. Using relative paths in CMakelists, since this should make VC++ put the files at the correct location.
parent d8c061fc
This diff is collapsed.
#OPTION( BUILD_SHARED_LIBS "Set to OFF to build static libraries" ON )
INCLUDE_DIRECTORIES("${PROJECT_SOURCE_DIR}/")
set(LIBPREFIX "lib") #make sure ALL plugins are libXXX for ALL plateforms
set(CMAKE_IMPORT_LIBRARY_PREFIX "lib") #for Visual C++ import libraries
SET(LIBPREFIX "lib") #make sure ALL plugins are libXXX for ALL plateforms
SET(CMAKE_IMPORT_LIBRARY_PREFIX "lib") #for Visual C++ import libraries
#SET(CMAKE_SHARED_LIBRARY_PREFIX "lib")
IF(PROJ4)
FIND_PATH(LIBPROJ_INCLUDE_DIR "proj_api.h")
FIND_LIBRARY(LIBPROJ proj)
INCLUDE_DIRECTORIES(${LIBPROJ_INCLUDE_DIR})
ADD_DEFINITIONS(-DPROJ4) #it looks like some VC++ versions don't support -D syntax
FIND_PATH(LIBPROJ_INCLUDE_DIR "proj_api.h")
FIND_LIBRARY(LIBPROJ proj)
INCLUDE_DIRECTORIES(${LIBPROJ_INCLUDE_DIR})
ADD_DEFINITIONS(-DPROJ4) #it looks like some VC++ versions don't support -D syntax
ENDIF(PROJ4)
INCLUDE("${PROJECT_SOURCE_DIR}/meteoio/meteolaws/CMakeLists.txt")
......@@ -49,75 +49,73 @@ SET(meteoio_sources
)
if (DEST MATCHES "par")
SET(CMAKE_CXX_SOURCE_FILE_EXTENSIONS cc;ph;)
SET(CMAKE_CXX_SOURCE_FILE_EXTENSIONS cc;ph;)
SET(meteoio_sources
marshal_meteoio.cc
IOHandler.ph
#IOManager.ph
${meteoio_sources}
)
SET_SOURCE_FILES_PROPERTIES( ${meteoio_sources} PROPERTIES LANGUAGE CXX )
SET_SOURCE_FILES_PROPERTIES( IOHandler.ph PROPERTIES KEEP_EXTENSION TRUE)
#SET_SOURCE_FILES_PROPERTIES( IOManager.ph PROPERTIES KEEP_EXTENSION TRUE)
SET(STATICNAME ${PROJECT_NAME}_STATIC_par)
SET(STATICLIBNAME ${PROJECT_NAME}popc)
ADD_LIBRARY(${STATICNAME} STATIC ${meteoio_sources})
TARGET_LINK_LIBRARIES(${STATICNAME} ${LIBPROJ})
#SET(SHAREDNAME ${PROJECT_NAME}_par)
INCLUDE(CMakeForceCompiler)
#CMAKE_FORCE_C_COMPILER(popcc POPCC)
CMAKE_FORCE_CXX_COMPILER(popcc POPCC)
SET(meteoio_sources
marshal_meteoio.cc
IOHandler.ph
#IOManager.ph
${meteoio_sources}
)
SET_SOURCE_FILES_PROPERTIES( ${meteoio_sources} PROPERTIES LANGUAGE CXX )
SET_SOURCE_FILES_PROPERTIES( IOHandler.ph PROPERTIES KEEP_EXTENSION TRUE)
#SET_SOURCE_FILES_PROPERTIES( IOManager.ph PROPERTIES KEEP_EXTENSION TRUE)
SET(STATICNAME ${PROJECT_NAME}_STATIC_par)
SET(STATICLIBNAME ${PROJECT_NAME}popc)
ADD_LIBRARY(${STATICNAME} STATIC ${meteoio_sources})
TARGET_LINK_LIBRARIES(${STATICNAME} ${LIBPROJ})
#SET(SHAREDNAME ${PROJECT_NAME}_par)
INCLUDE(CMakeForceCompiler)
#CMAKE_FORCE_C_COMPILER(popcc POPCC)
CMAKE_FORCE_CXX_COMPILER(popcc POPCC)
ADD_CUSTOM_COMMAND(
OUTPUT "${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o"
COMMAND popcc -o ${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o -c ${PROJECT_SOURCE_DIR}/meteoio/PackMeteoIO.cc -I${PROJECT_SOURCE_DIR} -combine -pipe "${ARCH} ${OPTIM} ${CFLAGS} ${PLATFORM} ${WARNINGS} ${EXTRA_WARNINGS}"
DEPENDS ${STATICNAME}
)
ADD_CUSTOM_COMMAND(
OUTPUT "${PROJECT_SOURCE_DIR}/lib/meteoio.module"
COMMAND popcc -object -parocld=c++ -o ${PROJECT_SOURCE_DIR}/lib/meteoio.module ${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o -L${PROJECT_SOURCE_DIR}/lib -lmeteoiopopc -rdynamic -lc -ldl -lm -lstdc++ ${LIBPROJ}
DEPENDS ${STATICNAME} ${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o
)
ADD_CUSTOM_COMMAND(
OUTPUT "${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o"
COMMAND popcc -o ${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o -c ${PROJECT_SOURCE_DIR}/meteoio/PackMeteoIO.cc -I${PROJECT_SOURCE_DIR} -combine -pipe "${ARCH} ${OPTIM} ${CFLAGS} ${PLATFORM} ${WARNINGS} ${EXTRA_WARNINGS}"
DEPENDS ${STATICNAME}
)
ADD_CUSTOM_COMMAND(
OUTPUT ${PROJECT_SOURCE_DIR}/lib/meteoio.module
COMMAND popcc -object -parocld=c++ -o ${PROJECT_SOURCE_DIR}/lib/meteoio.module ${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o -L${PROJECT_SOURCE_DIR}/lib -lmeteoiopopc -rdynamic -lc -ldl -lm -lstdc++ ${LIBPROJ}
DEPENDS ${STATICNAME} ${PROJECT_SOURCE_DIR}/lib/PackMeteoIO.o
)
ADD_CUSTOM_TARGET(weirdstuff ALL DEPENDS lib/meteoio.module)
ELSE(DEST MATCHES "par")
SET(STATICNAME ${PROJECT_NAME}_STATIC)
SET(STATICLIBNAME ${PROJECT_NAME})
ADD_LIBRARY(${STATICNAME} STATIC ${meteoio_sources})
TARGET_LINK_LIBRARIES(${STATICNAME} ${LIBPROJ})
ADD_CUSTOM_TARGET(weirdstuff ALL DEPENDS ${PROJECT_SOURCE_DIR}/lib/meteoio.module)
ELSE(DEST)
set(STATICNAME ${PROJECT_NAME}_STATIC)
SET(STATICLIBNAME ${PROJECT_NAME})
set(SHAREDNAME ${PROJECT_NAME})
ADD_LIBRARY(${SHAREDNAME} ${meteoio_sources})
TARGET_LINK_LIBRARIES(${SHAREDNAME} ${LIBPROJ})
ADD_LIBRARY(${STATICNAME} STATIC ${meteoio_sources})
TARGET_LINK_LIBRARIES(${STATICNAME} ${LIBPROJ})
SET_TARGET_PROPERTIES(${SHAREDNAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
CLEAN_DIRECT_OUTPUT 1
VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}"
SOVERSION "${VERSION_MAJOR}"
)
INSTALL(TARGETS ${SHAREDNAME}
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
COMPONENT libraries
)
endif(DEST MATCHES "par")
SET(SHAREDNAME ${PROJECT_NAME})
ADD_LIBRARY(${SHAREDNAME} ${meteoio_sources})
TARGET_LINK_LIBRARIES(${SHAREDNAME} ${LIBPROJ})
SET_TARGET_PROPERTIES(${SHAREDNAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY lib
ARCHIVE_OUTPUT_DIRECTORY lib
CLEAN_DIRECT_OUTPUT 1
VERSION "${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}"
SOVERSION "${VERSION_MAJOR}"
)
INSTALL(TARGETS ${SHAREDNAME}
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
COMPONENT libraries
)
ENDIF(DEST MATCHES "par")
#static library
SET_TARGET_PROPERTIES(${STATICNAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib
CLEAN_DIRECT_OUTPUT 1
OUTPUT_NAME ${STATICLIBNAME}
)
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY lib
ARCHIVE_OUTPUT_DIRECTORY lib
CLEAN_DIRECT_OUTPUT 1
OUTPUT_NAME ${STATICLIBNAME}
)
INSTALL(TARGETS ${STATICNAME}
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
COMPONENT libraries
)
RUNTIME DESTINATION bin
LIBRARY DESTINATION lib
ARCHIVE DESTINATION lib
COMPONENT libraries
)
......@@ -18,7 +18,7 @@
#ifndef __FILTERMAX_H__
#define __FILTERMAX_H__
//#define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember))
//#define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember))
#include <meteoio/meteofilters/FilterBlock.h>
#include <vector>
......@@ -35,10 +35,10 @@ namespace mio {
* Reject all values greater than the max. Remarks:
* - the maximum permissible value has to be provided has an argument (in SI)
* - the keyword "soft" maybe added, in such a case all data greater than the max would be assigned
* the maximum permissible value
* either the maximum permissible value or another value given as an extra argument (350 in the example below)
* @code
* TA::filter1 = max
* TA::arg1 = 330
* TA::arg1 = soft 330 350
* @endcode
*/
......
......@@ -18,7 +18,7 @@
#ifndef __FILTERMIN_H__
#define __FILTERMIN_H__
//#define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember))
//#define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember))
#include <meteoio/meteofilters/FilterBlock.h>
#include <vector>
......@@ -35,7 +35,7 @@ namespace mio {
* Reject all values smaller than the min. Remarks:
* - the minimum permissible value has to be provided has an argument (in SI)
* - the keyword "soft" maybe added, in such a case all data smaller than the min would be assigned
* the minimum permissible value
* either the minimum permissible value or another value given as an extra argument
* @code
* TA::filter1 = min
* TA::arg1 = 230
......
......@@ -18,7 +18,7 @@
#ifndef __FILTERMINMAX_H__
#define __FILTERMINMAX_H__
//#define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember))
//#define CALL_MEMBER_FN(object,ptrToMember) ((object).*(ptrToMember))
#include <meteoio/meteofilters/FilterBlock.h>
#include <vector>
......@@ -36,11 +36,14 @@ namespace mio {
* - two arguments have to be provided, min and max (in SI)
* - the keyword "soft" maybe added, in such a case all data greater than the max would be assigned
* the maximum permissible value and all data smaller than the min would be assigned the minimum permissible value
* or an optional extra set of two user provided values (see example below)
* @code
* TA::filter1 = min_max
* TA::arg1 = 230 330
* ISWR::filter1 = min_max
* ISWR::arg1 = soft 8 1500 0 1498
* @endcode
*
*
*/
class FilterMinMax : public FilterBlock {
......
......@@ -41,7 +41,7 @@ ELSE(DEST)
SET(SHAREDNAME ${PROJECT_NAME})
ENDIF(DEST MATCHES "par")
LINK_DIRECTORIES(${CMAKE_BINARY_DIR}/lib)
#LINK_DIRECTORIES(lib)
IF(PLUGIN_SMETIO)
ADD_LIBRARY(${SMETIONAME} SMETIO.cc)
......@@ -49,7 +49,7 @@ IF(PLUGIN_SMETIO)
TARGET_LINK_LIBRARIES(${SMETIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${SMETIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${SMETIONAME})
......@@ -58,9 +58,9 @@ ENDIF(PLUGIN_SMETIO)
IF(PLUGIN_ARCIO)
ADD_LIBRARY(${ARCIONAME} ARCIO.cc)
TARGET_LINK_LIBRARIES(${ARCIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${ARCIONAME} PROPERTIES
SET_TARGET_PROPERTIES(${ARCIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${ARCIONAME})
......@@ -69,9 +69,9 @@ ENDIF(PLUGIN_ARCIO)
IF(PLUGIN_PGMIO)
ADD_LIBRARY(${PGMIONAME} PGMIO.cc)
TARGET_LINK_LIBRARIES(${PGMIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${PGMIONAME} PROPERTIES
SET_TARGET_PROPERTIES(${PGMIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${PGMIONAME})
......@@ -82,7 +82,7 @@ IF(PLUGIN_ARPSIO)
TARGET_LINK_LIBRARIES(${ARPSIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${ARPSIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${ARPSIONAME})
......@@ -93,7 +93,7 @@ IF(PLUGIN_GRASSIO)
TARGET_LINK_LIBRARIES(${GRASSIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${GRASSIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${GRASSIONAME})
......@@ -104,7 +104,7 @@ IF(PLUGIN_GEOTOPIO)
TARGET_LINK_LIBRARIES(${GEOTOPIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${GEOTOPIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${GEOTOPIONAME})
......@@ -115,7 +115,7 @@ IF(PLUGIN_SNIO)
TARGET_LINK_LIBRARIES(${SNIONAME} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${SNIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${SNIONAME})
......@@ -132,7 +132,7 @@ IF(PLUGIN_GSNIO)
ADD_DEPENDENCIES(${GSNIONAME} wsdl2cpp gsnclient)
SET_TARGET_PROPERTIES(${GSNIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
#necessary because gsoap uses long long
......@@ -147,7 +147,7 @@ IF(PLUGIN_IMISIO)
TARGET_LINK_LIBRARIES(${IMISIONAME} ${OCCI_LIBRARIES} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${IMISIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${IMISIONAME})
......@@ -160,7 +160,7 @@ IF(PLUGIN_BORMAIO)
TARGET_LINK_LIBRARIES(${BORMAIONAME} ${LibXML++_LIBRARIES} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${BORMAIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${BORMAIONAME})
......@@ -173,7 +173,7 @@ IF(PLUGIN_COSMOXMLIO)
TARGET_LINK_LIBRARIES(${COSMOXMLIONAME} ${LibXML++_LIBRARIES} ${SHAREDNAME})
SET_TARGET_PROPERTIES(${COSMOXMLIONAME} PROPERTIES
PREFIX "${LIBPREFIX}"
LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib/plugins
LIBRARY_OUTPUT_DIRECTORY lib/plugins
VERSION ${VERSION_MAJOR}.${VERSION_MINOR}.${VERSION_PATCH}
SOVERSION ${VERSION_MAJOR})
SET(MYPLUGINS ${MYPLUGINS} ${COSMOXMLIONAME})
......
......@@ -33,6 +33,9 @@ namespace mio {
* If no such metadata file is provided, the metadata will be left nodata. This only makes sense
* if the metadata would be later filled by another way (like a merge).
*
* Finally, when writing to a file, the header line will only be created if the file does not already exist. If the
* file already exists on the disk, new data will be appended without attempting to write a header line.
*
* @section snowpack_units Units
* - temperatures in degrees Celsius (input and output) or in kelvins (input only)
* - relative humidity in % (input and output) or in [0;1] (input only)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment