Drop 0.19.6, fix soloud test
This commit is contained in:
parent
1b63a125c5
commit
da9a1c983b
11 changed files with 29 additions and 52 deletions
|
|
@ -11,13 +11,13 @@ language: c
|
||||||
|
|
||||||
env:
|
env:
|
||||||
- BRANCH=0.20.2
|
- BRANCH=0.20.2
|
||||||
- BRANCH=1.0.4
|
- BRANCH=1.0.6
|
||||||
- BRANCH=devel
|
- BRANCH=devel
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
directories:
|
directories:
|
||||||
- "$HOME/.choosenim/toolchains/nim-0.20.2"
|
- "$HOME/.choosenim/toolchains/nim-0.20.2"
|
||||||
- "$HOME/.choosenim/toolchains/nim-1.0.4"
|
- "$HOME/.choosenim/toolchains/nim-1.0.6"
|
||||||
|
|
||||||
install:
|
install:
|
||||||
- export CHOOSENIM_CHOOSE_VERSION=$BRANCH
|
- export CHOOSENIM_CHOOSE_VERSION=$BRANCH
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ matrix:
|
||||||
environment:
|
environment:
|
||||||
matrix:
|
matrix:
|
||||||
- NIM_VERSION: 0.20.2
|
- NIM_VERSION: 0.20.2
|
||||||
- NIM_VERSION: 1.0.4
|
- NIM_VERSION: 1.0.6
|
||||||
|
|
||||||
for:
|
for:
|
||||||
-
|
-
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ installDirs = @["nimterop"]
|
||||||
installFiles = @["config.nims"]
|
installFiles = @["config.nims"]
|
||||||
|
|
||||||
# Dependencies
|
# Dependencies
|
||||||
requires "nim >= 0.19.6", "regex >= 0.13.0", "cligen >= 0.9.41"
|
requires "nim >= 0.20.2", "regex >= 0.13.1", "cligen >= 0.9.43"
|
||||||
|
|
||||||
import nimterop/docs
|
import nimterop/docs
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,4 +4,4 @@ Module that should import everything so that `nim doc --project nimtero/all` run
|
||||||
|
|
||||||
# TODO: make sure it does import everything.
|
# TODO: make sure it does import everything.
|
||||||
|
|
||||||
import "."/[cimport, build, types, plugin, compat]
|
import "."/[cimport, build, types, plugin]
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,6 @@ import hashes, macros, osproc, sets, strformat, strutils, tables
|
||||||
|
|
||||||
import os except findExe, sleep
|
import os except findExe, sleep
|
||||||
|
|
||||||
import "."/[compat]
|
|
||||||
|
|
||||||
proc sanitizePath*(path: string, noQuote = false, sep = $DirSep): string =
|
proc sanitizePath*(path: string, noQuote = false, sep = $DirSep): string =
|
||||||
result = path.multiReplace([("\\\\", sep), ("\\", sep), ("/", sep)])
|
result = path.multiReplace([("\\\\", sep), ("\\", sep), ("/", sep)])
|
||||||
if not noQuote:
|
if not noQuote:
|
||||||
|
|
@ -648,7 +646,7 @@ proc getGccPaths*(mode = "c"): seq[string] =
|
||||||
break
|
break
|
||||||
if inc:
|
if inc:
|
||||||
var
|
var
|
||||||
path = line.strip().myNormalizedPath()
|
path = line.strip().normalizedPath()
|
||||||
if path notin result:
|
if path notin result:
|
||||||
result.add path
|
result.add path
|
||||||
|
|
||||||
|
|
@ -667,13 +665,13 @@ proc getGccLibPaths*(mode = "c"): seq[string] =
|
||||||
if "LIBRARY_PATH=" in line:
|
if "LIBRARY_PATH=" in line:
|
||||||
for path in line[13 .. ^1].split(PathSep):
|
for path in line[13 .. ^1].split(PathSep):
|
||||||
var
|
var
|
||||||
path = path.strip().myNormalizedPath()
|
path = path.strip().normalizedPath()
|
||||||
if path notin result:
|
if path notin result:
|
||||||
result.add path
|
result.add path
|
||||||
break
|
break
|
||||||
elif '\t' in line:
|
elif '\t' in line:
|
||||||
var
|
var
|
||||||
path = line.strip().myNormalizedPath()
|
path = line.strip().normalizedPath()
|
||||||
if path notin result:
|
if path notin result:
|
||||||
result.add path
|
result.add path
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@ const CIMPORT {.used.} = 1
|
||||||
|
|
||||||
include "."/globals
|
include "."/globals
|
||||||
|
|
||||||
import "."/[build, compat, paths, types]
|
import "."/[build, paths, types]
|
||||||
export types
|
export types
|
||||||
|
|
||||||
proc interpPath(dir: string): string=
|
proc interpPath(dir: string): string=
|
||||||
|
|
|
||||||
|
|
@ -1,22 +1,18 @@
|
||||||
import macros, strformat
|
import macros, strformat
|
||||||
|
|
||||||
when (NimMajor, NimMinor, NimPatch) >= (0, 19, 9):
|
from os import parentDir, getCurrentCompilerExe, DirSep
|
||||||
from os import parentDir, getCurrentCompilerExe, DirSep
|
proc getNimRootDir(): string =
|
||||||
proc getNimRootDir(): string =
|
#[
|
||||||
#[
|
hack, but works
|
||||||
hack, but works
|
alternatively (but more complex), use (from a nim file, not nims otherwise
|
||||||
alternatively (but more complex), use (from a nim file, not nims otherwise
|
you get Error: ambiguous call; both system.fileExists):
|
||||||
you get Error: ambiguous call; both system.fileExists):
|
import "$nim/testament/lib/stdtest/specialpaths.nim"
|
||||||
import "$nim/testament/lib/stdtest/specialpaths.nim"
|
nimRootDir
|
||||||
nimRootDir
|
]#
|
||||||
]#
|
fmt"{currentSourcePath}".parentDir.parentDir.parentDir
|
||||||
fmt"{currentSourcePath}".parentDir.parentDir.parentDir
|
|
||||||
else:
|
|
||||||
proc getCurrentCompilerExe*(): string =
|
|
||||||
"nim"
|
|
||||||
|
|
||||||
const
|
const
|
||||||
DirSep = when defined(windows): '\\' else: '/'
|
DirSep = when defined(windows): '\\' else: '/'
|
||||||
|
|
||||||
proc execAction(cmd: string): string =
|
proc execAction(cmd: string): string =
|
||||||
var
|
var
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import dynlib, macros, os, sequtils, sets, strformat, strutils, tables, times
|
||||||
|
|
||||||
import regex
|
import regex
|
||||||
|
|
||||||
import "."/[build, compat, globals, plugin, treesitter/api]
|
import "."/[build, globals, plugin, treesitter/api]
|
||||||
|
|
||||||
const gReserved = """
|
const gReserved = """
|
||||||
addr and as asm
|
addr and as asm
|
||||||
|
|
@ -505,6 +505,6 @@ proc loadPlugin*(gState: State, sourcePath: string) =
|
||||||
|
|
||||||
proc expandSymlinkAbs*(path: string): string =
|
proc expandSymlinkAbs*(path: string): string =
|
||||||
try:
|
try:
|
||||||
result = path.expandSymlink().absolutePath(path.parentDir()).myNormalizedPath()
|
result = path.expandSymlink().absolutePath(path.parentDir()).normalizedPath()
|
||||||
except:
|
except:
|
||||||
result = path
|
result = path
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import os, osproc, strformat, strutils, times
|
||||||
|
|
||||||
import "."/treesitter/[api, c, cpp]
|
import "."/treesitter/[api, c, cpp]
|
||||||
|
|
||||||
import "."/[ast, compat, globals, getters, grammar]
|
import "."/[ast, globals, getters, grammar]
|
||||||
|
|
||||||
proc printLisp(gState: State, root: TSNode) =
|
proc printLisp(gState: State, root: TSNode) =
|
||||||
var
|
var
|
||||||
|
|
|
||||||
|
|
@ -1,26 +1,9 @@
|
||||||
# see https://github.com/nimterop/nimterop/issues/79
|
# see https://github.com/nimterop/nimterop/issues/79
|
||||||
|
|
||||||
when (NimMajor, NimMinor, NimPatch) < (0, 19, 9):
|
import std/time_t as time_t_temp
|
||||||
# clean this up once upgraded; adapted from std/time_t
|
type
|
||||||
when defined(nimdoc):
|
time_t* = time_t_temp.Time
|
||||||
type
|
time64_t* = time_t_temp.Time
|
||||||
impl = distinct int64
|
|
||||||
Time = impl
|
|
||||||
elif defined(windows):
|
|
||||||
when defined(i386) and defined(gcc):
|
|
||||||
type Time {.importc: "time_t", header: "<time.h>".} = distinct int32
|
|
||||||
else:
|
|
||||||
type Time {.importc: "time_t", header: "<time.h>".} = distinct int64
|
|
||||||
elif defined(posix):
|
|
||||||
import posix
|
|
||||||
type
|
|
||||||
time_t* = Time
|
|
||||||
time64_t* = Time
|
|
||||||
else:
|
|
||||||
import std/time_t as time_t_temp
|
|
||||||
type
|
|
||||||
time_t* = time_t_temp.Time
|
|
||||||
time64_t* = time_t_temp.Time
|
|
||||||
|
|
||||||
when defined(cpp):
|
when defined(cpp):
|
||||||
# http://www.cplusplus.com/reference/cwchar/wchar_t/
|
# http://www.cplusplus.com/reference/cwchar/wchar_t/
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ else:
|
||||||
|
|
||||||
cCompile(src/"c_api/soloud_c.cpp")
|
cCompile(src/"c_api/soloud_c.cpp")
|
||||||
cCompile(src/"core/*.cpp")
|
cCompile(src/"core/*.cpp")
|
||||||
cCompile(src/"audiosource", "cpp")
|
cCompile(src/"audiosource", "cpp", exclude="ay/")
|
||||||
cCompile(src/"audiosource", "c")
|
cCompile(src/"audiosource", "c")
|
||||||
cCompile(src/"filter/*.cpp")
|
cCompile(src/"filter/*.cpp")
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue