File tree Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Expand file tree Collapse file tree 1 file changed +7
-2
lines changed Original file line number Diff line number Diff line change @@ -13,11 +13,16 @@ builder.appendUnique('CXXFLAGS', [ '-I' + ociIncludeDir ]);
13
13
14
14
ociLibDir = process . env [ "OCI_LIB_DIR" ] || "/usr/lib/oracle/11.2/client/lib/" ;
15
15
builder . failIfNotExists ( ociLibDir , 'Could not find "%s" check OCI_LIB_DIR environment variable.' ) ;
16
- builder . appendUnique ( 'LINKFLAGS' , [ '-L' + ociLibDir ] ) ;
16
+ builder . appendLinkerSearchDir ( ociLibDir ) ;
17
17
18
18
builder . appendLinkerLibrary ( "occi" ) ;
19
19
builder . appendLinkerLibrary ( "clntsh" ) ;
20
- builder . appendLinkerLibrary ( "nnz11" ) ;
20
+ if ( path . existsSync ( path . join ( ociLibDir , "libnnz10.dylib" ) )
21
+ || path . existsSync ( path . join ( ociLibDir , "libnnz10.so" ) ) ) {
22
+ builder . appendLinkerLibrary ( "nnz10" ) ;
23
+ } else {
24
+ builder . appendLinkerLibrary ( "nnz11" ) ;
25
+ }
21
26
22
27
builder . target = "oracle_bindings"
23
28
builder . appendSourceDir ( './src' ) ;
You can’t perform that action at this time.
0 commit comments