Skip to content

Commit 6cf3a0e

Browse files
committed
add warning
Signed-off-by: Anton Dukhovnikov <[email protected]>
1 parent 87a5f97 commit 6cf3a0e

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

include/rawtoaces/define.h

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
#include <string>
5858
#include <algorithm>
5959
#include <boost/filesystem.hpp>
60+
#include <iostream>
6061

6162
#ifndef WIN32
6263
# include <sys/stat.h>
@@ -455,9 +456,18 @@ inline dataPath &pathsFinder()
455456

456457
env = getenv( "RAWTOACES_DATA_PATH" );
457458
if ( !env )
459+
{
458460
// Fallback to the old environment variable.
459461
env = getenv( "AMPAS_DATA_PATH" );
460462

463+
if ( env )
464+
{
465+
std::cerr << "Warning: The environment variable "
466+
<< "AMPAS_DATA_PATH is now deprecated. Please use "
467+
<< "RAWTOACES_DATA_PATH instead." << std::endl;
468+
}
469+
}
470+
461471
if ( env )
462472
path = env;
463473

0 commit comments

Comments
 (0)