convert global string "constants" to macros

avoid instantiating in all compilation units.
This commit is contained in:
Michael Davidsaver
2017-12-29 11:41:47 -06:00
parent 3bb2f25bed
commit 49b2507985
2 changed files with 4 additions and 4 deletions

View File

@@ -46,7 +46,7 @@ void startitup() {
the_server = pva::ServerContext::create(pva::ServerContext::Config()
.config(pva::ConfigurationBuilder()
// default to all providers instead of just "local"
.add("EPICS_PVAS_PROVIDER_NAMES", pva::PVACCESS_ALL_PROVIDERS)
.add("EPICS_PVAS_PROVIDER_NAMES", PVACCESS_ALL_PROVIDERS)
.push_map()
// prefer to use EPICS_PVAS_PROVIDER_NAMES
// from environment

View File

@@ -73,13 +73,13 @@ const epics::pvData::int16 INVALID_DATA_TYPE = static_cast<epics::pvData::int16>
const epics::pvData::int32 INVALID_IOID = 0;
/** Default PVA provider name. */
const std::string PVACCESS_DEFAULT_PROVIDER = "local";
#define PVACCESS_DEFAULT_PROVIDER "local"
/** "All-providers registered" PVA provider name. */
const std::string PVACCESS_ALL_PROVIDERS = "<all>";
#define PVACCESS_ALL_PROVIDERS "<all>"
/** Name of the system env. variable to turn on debugging. */
const std::string PVACCESS_DEBUG = "EPICS_PVA_DEBUG";
#define PVACCESS_DEBUG "EPICS_PVA_DEBUG"
}
}