diff --git a/CMakeLists.txt b/CMakeLists.txt index bc01f1355..bb5f536a3 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -95,9 +95,9 @@ add_custom_target(opm-material_prepare) opm_add_test(test_blackoilfluidstate) opm_add_test(test_ConditionalStorage) -opm_add_test(test_eclblackoilfluidsystem CONDITION HAVE_ECL_INPUT) -opm_add_test(test_eclblackoilpvt CONDITION HAVE_ECL_INPUT) -opm_add_test(test_eclmateriallawmanager CONDITION HAVE_ECL_INPUT) +opm_add_test(test_eclblackoilfluidsystem) +opm_add_test(test_eclblackoilpvt) +opm_add_test(test_eclmateriallawmanager) opm_add_test(test_fluidmatrixinteractions) opm_add_test(test_pengrobinson) opm_add_test(test_densead) diff --git a/opm-material-prereqs.cmake b/opm-material-prereqs.cmake index 691fc9b6d..1b1106e75 100644 --- a/opm-material-prereqs.cmake +++ b/opm-material-prereqs.cmake @@ -4,7 +4,6 @@ set (opm-material_CONFIG_VAR HAVE_TYPE_TRAITS HAVE_VALGRIND HAVE_FINAL - HAVE_ECL_INPUT ) # dependencies diff --git a/opm/material/common/Exceptions.hpp b/opm/material/common/Exceptions.hpp index 3c4d9ea72..b062d153e 100644 --- a/opm/material/common/Exceptions.hpp +++ b/opm/material/common/Exceptions.hpp @@ -27,9 +27,7 @@ #ifndef OPM_MATERIAL_EXCEPTIONS_HPP #define OPM_MATERIAL_EXCEPTIONS_HPP -#if HAVE_OPM_COMMON #include -#endif #include @@ -38,19 +36,11 @@ // the opm-material specific exception classes namespace Opm { class NumericalIssue -#if HAVE_OPM_COMMON : public Opm::NumericalProblem -#else - : public std::runtime_error -#endif { public: explicit NumericalIssue(const std::string &message) -#if HAVE_OPM_COMMON : Opm::NumericalProblem(message) -#else - : std::runtime_error(message) -#endif {} }; } diff --git a/opm/material/fluidmatrixinteractions/EclEpsConfig.hpp b/opm/material/fluidmatrixinteractions/EclEpsConfig.hpp index 5a382ef4a..39beadb1c 100644 --- a/opm/material/fluidmatrixinteractions/EclEpsConfig.hpp +++ b/opm/material/fluidmatrixinteractions/EclEpsConfig.hpp @@ -27,13 +27,11 @@ #ifndef OPM_ECL_EPS_CONFIG_HPP #define OPM_ECL_EPS_CONFIG_HPP -#if HAVE_ECL_INPUT #include #include #include #include #include -#endif #include #include @@ -155,7 +153,6 @@ class EclEpsConfig bool enableLeverettScaling() const { return enableLeverettScaling_; } -#if HAVE_ECL_INPUT /*! * \brief Reads all relevant material parameters form a cell of a parsed ECL deck. * @@ -238,7 +235,6 @@ class EclEpsConfig enableKrnScaling_ = props.hasDeckDoubleGridProperty("KRG"); } } -#endif private: // enable scaling of the input saturations (i.e., rescale the x-Axis) diff --git a/opm/material/fluidmatrixinteractions/EclEpsScalingPoints.hpp b/opm/material/fluidmatrixinteractions/EclEpsScalingPoints.hpp index 27fbd9730..f785efd0b 100644 --- a/opm/material/fluidmatrixinteractions/EclEpsScalingPoints.hpp +++ b/opm/material/fluidmatrixinteractions/EclEpsScalingPoints.hpp @@ -29,7 +29,6 @@ #include "EclEpsConfig.hpp" -#if HAVE_ECL_INPUT #include #include #include @@ -42,7 +41,6 @@ #include #include #include -#endif #include @@ -66,7 +64,6 @@ class EclEpsGridProperties typedef std::vector DoubleData; public: -#if HAVE_ECL_INPUT void initFromDeck(const Opm::Deck& /* deck */, const Opm::EclipseState& eclState, bool useImbibition) @@ -108,7 +105,6 @@ class EclEpsGridProperties if (ecl3dProps.hasDeckDoubleGridProperty("PERMZ")) permz = &ecl3dProps.getDoubleGridProperty("PERMZ").getData(); } -#endif const IntData* satnum; @@ -131,7 +127,6 @@ class EclEpsGridProperties const DoubleData* permz; private: -#if HAVE_ECL_INPUT // this method makes sure that a grid property is not created if it is not explicitly // mentioned in the deck. (saves memory.) void retrieveGridPropertyData_(const DoubleData **data, @@ -142,7 +137,6 @@ class EclEpsGridProperties if (eclState.get3DProperties().hasDeckDoubleGridProperty(properyName)) (*data) = &eclState.get3DProperties().getDoubleGridProperty(properyName).getData(); } -#endif }; /*! @@ -214,7 +208,6 @@ struct EclEpsScalingPointsInfo << " maxKrog: " << maxKrog << "\n"; } -#if HAVE_ECL_INPUT /*! * \brief Extract the values of the unscaled scaling parameters. * @@ -418,10 +411,8 @@ struct EclEpsScalingPointsInfo } } } -#endif private: -#if HAVE_ECL_INPUT void extractUnscaledSgof_(const Opm::SgofTable& sgofTable) { // minimum gas and oil-in-gas-oil saturation @@ -646,7 +637,6 @@ struct EclEpsScalingPointsInfo maxKrow = sof2Table.getKroColumn().back(); maxKrog = maxKrow; } -#endif // HAVE_ECL_INPUT void extractGridPropertyValue_(Scalar& targetValue, const std::vector* propData, diff --git a/opm/material/fluidmatrixinteractions/EclEpsTwoPhaseLawParams.hpp b/opm/material/fluidmatrixinteractions/EclEpsTwoPhaseLawParams.hpp index ef39df0c7..887c1c0d4 100644 --- a/opm/material/fluidmatrixinteractions/EclEpsTwoPhaseLawParams.hpp +++ b/opm/material/fluidmatrixinteractions/EclEpsTwoPhaseLawParams.hpp @@ -30,10 +30,8 @@ #include "EclEpsConfig.hpp" #include "EclEpsScalingPoints.hpp" -#if HAVE_ECL_INPUT #include #include -#endif #include #include diff --git a/opm/material/fluidmatrixinteractions/EclHysteresisConfig.hpp b/opm/material/fluidmatrixinteractions/EclHysteresisConfig.hpp index 41c60a469..f01721db6 100644 --- a/opm/material/fluidmatrixinteractions/EclHysteresisConfig.hpp +++ b/opm/material/fluidmatrixinteractions/EclHysteresisConfig.hpp @@ -27,12 +27,10 @@ #ifndef OPM_ECL_HYSTERESIS_CONFIG_HPP #define OPM_ECL_HYSTERESIS_CONFIG_HPP -#if HAVE_ECL_INPUT #include #include #include #include -#endif #include @@ -107,7 +105,6 @@ class EclHysteresisConfig int krHysteresisModel() const { return krHysteresisModel_; } -#if HAVE_ECL_INPUT /*! * \brief Reads all relevant material parameters form a cell of a parsed ECL deck. * @@ -170,7 +167,6 @@ class EclHysteresisConfig throw std::runtime_error("Capillary pressure hysteresis is not supported yet"); } } -#endif private: // enable hysteresis at all diff --git a/opm/material/fluidmatrixinteractions/EclHysteresisTwoPhaseLawParams.hpp b/opm/material/fluidmatrixinteractions/EclHysteresisTwoPhaseLawParams.hpp index b263cf24d..c2d7a2f9f 100644 --- a/opm/material/fluidmatrixinteractions/EclHysteresisTwoPhaseLawParams.hpp +++ b/opm/material/fluidmatrixinteractions/EclHysteresisTwoPhaseLawParams.hpp @@ -30,10 +30,8 @@ #include "EclHysteresisConfig.hpp" #include "EclEpsScalingPoints.hpp" -#if HAVE_ECL_INPUT #include #include -#endif #include #include diff --git a/opm/material/fluidmatrixinteractions/EclMaterialLawManager.hpp b/opm/material/fluidmatrixinteractions/EclMaterialLawManager.hpp index e52e33e01..1cf32dd2b 100644 --- a/opm/material/fluidmatrixinteractions/EclMaterialLawManager.hpp +++ b/opm/material/fluidmatrixinteractions/EclMaterialLawManager.hpp @@ -24,10 +24,6 @@ * \file * \copydoc Opm::EclMaterialLawManager */ -#if ! HAVE_ECL_INPUT -#error "Eclipse input support in opm-common is required to use the ECL material manager!" -#endif - #ifndef OPM_ECL_MATERIAL_LAW_MANAGER_HPP #define OPM_ECL_MATERIAL_LAW_MANAGER_HPP @@ -42,9 +38,7 @@ #include #include -#if HAVE_OPM_COMMON #include -#endif #include diff --git a/opm/material/fluidsystems/BlackOilFluidSystem.hpp b/opm/material/fluidsystems/BlackOilFluidSystem.hpp index d087f0088..f08af8142 100644 --- a/opm/material/fluidsystems/BlackOilFluidSystem.hpp +++ b/opm/material/fluidsystems/BlackOilFluidSystem.hpp @@ -158,7 +158,6 @@ class BlackOilFluidSystem : public BaseFluidSystem #include -#if HAVE_ECL_INPUT #include #include #include #include #include -#endif namespace Opm { /*! @@ -52,7 +50,6 @@ class ConstantCompressibilityOilPvt typedef std::vector > SamplingPoints; public: -#if HAVE_ECL_INPUT /*! * \brief Sets the pressure-dependent oil viscosity and density * using the Eclipse PVCDO keyword. @@ -92,7 +89,6 @@ class ConstantCompressibilityOilPvt initEnd(); } -#endif void setNumRegions(size_t numRegions) { diff --git a/opm/material/fluidsystems/blackoilpvt/ConstantCompressibilityWaterPvt.hpp b/opm/material/fluidsystems/blackoilpvt/ConstantCompressibilityWaterPvt.hpp index 697075348..6e1da88d8 100644 --- a/opm/material/fluidsystems/blackoilpvt/ConstantCompressibilityWaterPvt.hpp +++ b/opm/material/fluidsystems/blackoilpvt/ConstantCompressibilityWaterPvt.hpp @@ -29,13 +29,11 @@ #include -#if HAVE_ECL_INPUT #include #include #include #include #include -#endif #include @@ -51,7 +49,6 @@ class ConstantCompressibilityWaterPvt typedef std::vector > SamplingPoints; public: -#if HAVE_ECL_INPUT /*! * \brief Sets the pressure-dependent water viscosity and density * using a table stemming from the Eclipse PVTW keyword. @@ -87,7 +84,6 @@ class ConstantCompressibilityWaterPvt initEnd(); } -#endif void setNumRegions(size_t numRegions) { diff --git a/opm/material/fluidsystems/blackoilpvt/DeadOilPvt.hpp b/opm/material/fluidsystems/blackoilpvt/DeadOilPvt.hpp index f788c9296..58900f260 100644 --- a/opm/material/fluidsystems/blackoilpvt/DeadOilPvt.hpp +++ b/opm/material/fluidsystems/blackoilpvt/DeadOilPvt.hpp @@ -31,11 +31,9 @@ #include #include -#if HAVE_ECL_INPUT #include #include #include -#endif namespace Opm { /*! @@ -49,7 +47,6 @@ class DeadOilPvt typedef std::vector > SamplingPoints; public: -#if HAVE_ECL_INPUT /*! * \brief Initialize the oil parameters via the data specified by the PVDO ECL keyword. */ @@ -87,7 +84,6 @@ class DeadOilPvt initEnd(); } -#endif // HAVE_ECL_INPUT void setNumRegions(size_t numRegions) { diff --git a/opm/material/fluidsystems/blackoilpvt/DryGasPvt.hpp b/opm/material/fluidsystems/blackoilpvt/DryGasPvt.hpp index fb0b36e77..ab5bfa487 100644 --- a/opm/material/fluidsystems/blackoilpvt/DryGasPvt.hpp +++ b/opm/material/fluidsystems/blackoilpvt/DryGasPvt.hpp @@ -31,14 +31,12 @@ #include -#if HAVE_ECL_INPUT #include #include #include #include #include #include -#endif #include @@ -54,7 +52,6 @@ class DryGasPvt typedef std::vector > SamplingPoints; public: -#if HAVE_ECL_INPUT /*! * \brief Initialize the parameters for dry gas using an ECL deck. * @@ -104,7 +101,6 @@ class DryGasPvt initEnd(); } -#endif void setNumRegions(size_t numRegions) { diff --git a/opm/material/fluidsystems/blackoilpvt/GasPvtMultiplexer.hpp b/opm/material/fluidsystems/blackoilpvt/GasPvtMultiplexer.hpp index 6c4a30e5a..537c97b31 100644 --- a/opm/material/fluidsystems/blackoilpvt/GasPvtMultiplexer.hpp +++ b/opm/material/fluidsystems/blackoilpvt/GasPvtMultiplexer.hpp @@ -31,12 +31,10 @@ #include "WetGasPvt.hpp" #include "GasPvtThermal.hpp" -#if HAVE_ECL_INPUT #include #include #include #include -#endif namespace Opm { #define OPM_GAS_PVT_MULTIPLEXER_CALL(codeToCall) \ @@ -109,7 +107,6 @@ class GasPvtMultiplexer } } -#if HAVE_ECL_INPUT /*! * \brief Initialize the parameters for gas using an ECL deck. * @@ -130,7 +127,6 @@ class GasPvtMultiplexer OPM_GAS_PVT_MULTIPLEXER_CALL(pvtImpl.initFromDeck(deck, eclState)); } -#endif // HAVE_ECL_INPUT void setApproach(GasPvtApproach gasPvtAppr) { diff --git a/opm/material/fluidsystems/blackoilpvt/GasPvtThermal.hpp b/opm/material/fluidsystems/blackoilpvt/GasPvtThermal.hpp index 11e13e7b8..9fb772422 100644 --- a/opm/material/fluidsystems/blackoilpvt/GasPvtThermal.hpp +++ b/opm/material/fluidsystems/blackoilpvt/GasPvtThermal.hpp @@ -34,12 +34,10 @@ #include #include -#if HAVE_ECL_INPUT #include #include #include #include -#endif namespace Opm { template @@ -68,7 +66,6 @@ class GasPvtThermal ~GasPvtThermal() { delete isothermalPvt_; } -#if HAVE_ECL_INPUT /*! * \brief Implement the temperature part of the gas PVT properties. */ @@ -158,7 +155,6 @@ class GasPvtThermal } } } -#endif // HAVE_ECL_INPUT /*! * \brief Set the number of PVT-regions considered by this object. diff --git a/opm/material/fluidsystems/blackoilpvt/LiveOilPvt.hpp b/opm/material/fluidsystems/blackoilpvt/LiveOilPvt.hpp index 3280f2fdc..add0f4f3b 100644 --- a/opm/material/fluidsystems/blackoilpvt/LiveOilPvt.hpp +++ b/opm/material/fluidsystems/blackoilpvt/LiveOilPvt.hpp @@ -33,16 +33,12 @@ #include #include -#if HAVE_ECL_INPUT #include #include #include #include -#endif -#if HAVE_OPM_COMMON #include -#endif namespace Opm { /*! @@ -62,7 +58,6 @@ class LiveOilPvt vapPar2_ = 0.0; } -#if HAVE_ECL_INPUT /*! * \brief Initialize the oil parameters via the data specified by the PVTO ECL keyword. */ @@ -232,7 +227,6 @@ class LiveOilPvt } public: -#endif // HAVE_ECL_INPUT void setNumRegions(size_t numRegions) { diff --git a/opm/material/fluidsystems/blackoilpvt/OilPvtMultiplexer.hpp b/opm/material/fluidsystems/blackoilpvt/OilPvtMultiplexer.hpp index 72f3c0478..609073c12 100644 --- a/opm/material/fluidsystems/blackoilpvt/OilPvtMultiplexer.hpp +++ b/opm/material/fluidsystems/blackoilpvt/OilPvtMultiplexer.hpp @@ -115,7 +115,6 @@ class OilPvtMultiplexer } } -#if HAVE_ECL_INPUT /*! * \brief Initialize the parameters for water using an ECL deck. * @@ -138,7 +137,6 @@ class OilPvtMultiplexer OPM_OIL_PVT_MULTIPLEXER_CALL(pvtImpl.initFromDeck(deck, eclState)); } -#endif // HAVE_ECL_INPUT void initEnd() diff --git a/opm/material/fluidsystems/blackoilpvt/OilPvtThermal.hpp b/opm/material/fluidsystems/blackoilpvt/OilPvtThermal.hpp index 3de6b7874..a0938d71f 100644 --- a/opm/material/fluidsystems/blackoilpvt/OilPvtThermal.hpp +++ b/opm/material/fluidsystems/blackoilpvt/OilPvtThermal.hpp @@ -34,12 +34,10 @@ #include #include -#if HAVE_ECL_INPUT #include #include #include #include -#endif namespace Opm { template @@ -68,7 +66,6 @@ class OilPvtThermal ~OilPvtThermal() { delete isothermalPvt_; } -#if HAVE_ECL_INPUT /*! * \brief Implement the temperature part of the oil PVT properties. */ @@ -172,7 +169,6 @@ class OilPvtThermal } } } -#endif // HAVE_ECL_INPUT /*! * \brief Set the number of PVT-regions considered by this object. diff --git a/opm/material/fluidsystems/blackoilpvt/SolventPvt.hpp b/opm/material/fluidsystems/blackoilpvt/SolventPvt.hpp index 851f1ed56..6a788f413 100644 --- a/opm/material/fluidsystems/blackoilpvt/SolventPvt.hpp +++ b/opm/material/fluidsystems/blackoilpvt/SolventPvt.hpp @@ -31,14 +31,12 @@ #include -#if HAVE_ECL_INPUT #include #include #include #include #include #include -#endif #include @@ -54,7 +52,6 @@ class SolventPvt typedef std::vector > SamplingPoints; public: -#if HAVE_ECL_INPUT /*! * \brief Initialize the parameters for "solvent gas" using an ECL deck. * @@ -92,7 +89,6 @@ class SolventPvt initEnd(); } -#endif void setNumRegions(size_t numRegions) { diff --git a/opm/material/fluidsystems/blackoilpvt/WaterPvtMultiplexer.hpp b/opm/material/fluidsystems/blackoilpvt/WaterPvtMultiplexer.hpp index 897f61b58..a3a175866 100644 --- a/opm/material/fluidsystems/blackoilpvt/WaterPvtMultiplexer.hpp +++ b/opm/material/fluidsystems/blackoilpvt/WaterPvtMultiplexer.hpp @@ -84,7 +84,6 @@ class WaterPvtMultiplexer } } -#if HAVE_ECL_INPUT /*! * \brief Initialize the parameters for water using an ECL deck. * @@ -103,7 +102,6 @@ class WaterPvtMultiplexer OPM_WATER_PVT_MULTIPLEXER_CALL(pvtImpl.initFromDeck(deck, eclState)); } -#endif // HAVE_ECL_INPUT void initEnd() { OPM_WATER_PVT_MULTIPLEXER_CALL(pvtImpl.initEnd()); } diff --git a/opm/material/fluidsystems/blackoilpvt/WaterPvtThermal.hpp b/opm/material/fluidsystems/blackoilpvt/WaterPvtThermal.hpp index 79059656f..e8e8ca545 100644 --- a/opm/material/fluidsystems/blackoilpvt/WaterPvtThermal.hpp +++ b/opm/material/fluidsystems/blackoilpvt/WaterPvtThermal.hpp @@ -34,12 +34,10 @@ #include #include -#if HAVE_ECL_INPUT #include #include #include #include -#endif namespace Opm { template @@ -68,7 +66,6 @@ class WaterPvtThermal ~WaterPvtThermal() { delete isothermalPvt_; } -#if HAVE_ECL_INPUT /*! * \brief Implement the temperature part of the water PVT properties. */ @@ -169,7 +166,6 @@ class WaterPvtThermal } } } -#endif // HAVE_ECL_INPUT /*! * \brief Set the number of PVT-regions considered by this object. diff --git a/opm/material/fluidsystems/blackoilpvt/WetGasPvt.hpp b/opm/material/fluidsystems/blackoilpvt/WetGasPvt.hpp index 86417c0db..649bcac91 100644 --- a/opm/material/fluidsystems/blackoilpvt/WetGasPvt.hpp +++ b/opm/material/fluidsystems/blackoilpvt/WetGasPvt.hpp @@ -33,10 +33,8 @@ #include #include -#if HAVE_ECL_INPUT #include #include -#endif namespace Opm { @@ -57,7 +55,6 @@ class WetGasPvt vapPar1_ = 0.0; } -#if HAVE_ECL_INPUT /*! * \brief Initialize the parameters for wet gas using an ECL deck. * @@ -229,7 +226,6 @@ class WetGasPvt } public: -#endif // HAVE_ECL_INPUT void setNumRegions(size_t numRegions) { diff --git a/opm/material/thermal/EclThermalLawManager.hpp b/opm/material/thermal/EclThermalLawManager.hpp index 8337bcda5..c9f256973 100644 --- a/opm/material/thermal/EclThermalLawManager.hpp +++ b/opm/material/thermal/EclThermalLawManager.hpp @@ -24,9 +24,6 @@ * \file * \copydoc Opm::EclThermalLawManager */ -#if ! HAVE_ECL_INPUT -#error "Eclipse input support in opm-common is required to use the ECL thermal law manager!" -#endif #ifndef OPM_ECL_THERMAL_LAW_MANAGER_HPP #define OPM_ECL_THERMAL_LAW_MANAGER_HPP diff --git a/tests/test_eclblackoilfluidsystem.cpp b/tests/test_eclblackoilfluidsystem.cpp index 41b4a338e..7eca1f80f 100644 --- a/tests/test_eclblackoilfluidsystem.cpp +++ b/tests/test_eclblackoilfluidsystem.cpp @@ -29,10 +29,6 @@ */ #include "config.h" -#if !HAVE_ECL_INPUT -#error "The test for the black oil fluid system classes requires ecl input support in opm-common" -#endif - #include #include #include diff --git a/tests/test_eclblackoilpvt.cpp b/tests/test_eclblackoilpvt.cpp index d8766fb52..d4bfe67d9 100644 --- a/tests/test_eclblackoilpvt.cpp +++ b/tests/test_eclblackoilpvt.cpp @@ -29,10 +29,6 @@ */ #include "config.h" -#if !HAVE_ECL_INPUT -#error "The test for the black oil PVT classes requires eclipse input support in opm-common" -#endif - #include #include #include diff --git a/tests/test_eclmateriallawmanager.cpp b/tests/test_eclmateriallawmanager.cpp index 82813a522..037886795 100644 --- a/tests/test_eclmateriallawmanager.cpp +++ b/tests/test_eclmateriallawmanager.cpp @@ -30,10 +30,6 @@ */ #include "config.h" -#if !HAVE_ECL_INPUT -#error "The test for EclMaterialLawManager requires eclipse input support in opm-common" -#endif - #include #include diff --git a/tests/test_fluidsystems.cpp b/tests/test_fluidsystems.cpp index 5ba5f4a0e..9b6237e5f 100644 --- a/tests/test_fluidsystems.cpp +++ b/tests/test_fluidsystems.cpp @@ -71,11 +71,9 @@ void ensureBlackoilApi() // here we don't want to call these methods at runtime, we just want to make sure // that they compile while (false) { -#if HAVE_ECL_INPUT Opm::Deck deck; Opm::EclipseState eclState(deck); FluidSystem::initFromDeck(deck, eclState); -#endif typedef typename FluidSystem::Scalar Scalar; typedef Opm::CompositionalFluidState FluidState;