Skip to content

Commit 753ef87

Browse files
authored
Merge pull request #2007 from GenericMappingTools/bindir2libdir
Add a API flag to let bindir be set to libdir
2 parents 0c2045b + bbb4b92 commit 753ef87

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

src/get_enums.jl

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,11 @@ const global GMT_SESSION_EXTERNAL = 2 # Called by an external API
55
const global GMT_SESSION_COLMAJOR = 4 # External API uses column-major formats. [Row-major format]
66
const global GMT_SESSION_RUNMODE = 16 # If set enable GMT's modern runmode. [Classic]
77
const global GMT_SESSION_NOGDALCLOSE = 64 # External API tells GMT to not call GDALDestroyDriverManager()
8+
const global GMT_SESSION_BIN2LIBDIR = 128 # Reset bindir to libdir. The issue is that GMT->init.runtime_bindir is set to julia/bin
89

9-
const global GMT_SESSION_BITFLAGS = GMT_SESSION_NOEXIT + GMT_SESSION_EXTERNAL + GMT_SESSION_NOGDALCLOSE + GMT_SESSION_COLMAJOR
10+
bitflags = GMT_SESSION_NOEXIT + GMT_SESSION_EXTERNAL + GMT_SESSION_NOGDALCLOSE + GMT_SESSION_COLMAJOR
11+
Sys.iswindows() && (bitflags += GMT_SESSION_BIN2LIBDIR)
12+
const global GMT_SESSION_BITFLAGS = bitflags
1013
G_API[] = GMT_Create_Session("GMT", 2, GMT_SESSION_BITFLAGS)
1114

1215
enu = GMT_Get_Enum(G_API[], "GMT_CHAR"); const global GMT_CHAR = (enu != -99999) ? enu : 0

0 commit comments

Comments
 (0)