Fixes and test lzma/zlib with ast2

This commit is contained in:
Ganesh Viswanathan 2020-05-01 15:07:51 -05:00
commit 748998b0bd
6 changed files with 85 additions and 74 deletions

View file

@ -3,6 +3,8 @@ import os, strutils
import nimterop/[build, cimport]
const
FLAGS {.strdefine.} = ""
baseDir = getProjectCacheDir("nimterop" / "tests" / "zlib")
proc zlibPreBuild(outdir, path: string) =
@ -64,8 +66,8 @@ when zlibGit or zlibDL:
cIncludeDir(baseDir / "buildcache")
when not zlibStatic:
cImport(zlibPath, recurse = true, dynlib = "zlibLPath")
cImport(zlibPath, recurse = true, dynlib = "zlibLPath", flags = FLAGS)
else:
cImport(zlibPath, recurse = true)
cImport(zlibPath, recurse = true, flags = FLAGS)
echo "zlib version = " & $zlibVersion()