mirror of
https://github.com/osm-search/Nominatim.git
synced 2026-02-16 15:47:58 +00:00
remove old nominatim.py in favour of 'nominatim index'
The PHP scripts need to know the position of the nominatim tool in order to call it. This is handed in as environment variable, so it can be set by the Python script.
This commit is contained in:
@@ -8,5 +8,6 @@ require('@CMAKE_SOURCE_DIR@/lib/dotenv_loader.php');
|
||||
@define('CONST_DataDir', '@CMAKE_SOURCE_DIR@');
|
||||
|
||||
loadDotEnv();
|
||||
$_SERVER['NOMINATIM_NOMINATIM_TOOL'] = '@CMAKE_BINARY_DIR@/nominatim';
|
||||
|
||||
require_once('@CMAKE_SOURCE_DIR@/lib/admin/@script_source@');
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
#!/usr/bin/env python3
|
||||
import sys
|
||||
import os
|
||||
|
||||
sys.path.insert(1, '@CMAKE_SOURCE_DIR@')
|
||||
|
||||
os.environ['NOMINATIM_NOMINATIM_TOOL'] = __file__
|
||||
|
||||
from nominatim import cli
|
||||
|
||||
exit(cli.nominatim(module_dir='@CMAKE_BINARY_DIR@/module',
|
||||
|
||||
Reference in New Issue
Block a user