all repos — min @ 1dcffd7965a675670203960535eec938e4e0a758

A small but practical concatenative programming language.

Fixed hardcoded paths for static libs.
h3rald h3rald@h3rald.com
Mon, 17 Jul 2023 12:50:03 +0000
commit

1dcffd7965a675670203960535eec938e4e0a758

parent

a73e8f5d990a6662a76f321b8bb148960de7625e

M minpkg/core/interpreter.nimminpkg/core/interpreter.nim

@@ -301,7 +301,7 @@ body

except MinRuntimeError: let msg = getCurrentExceptionMsg() i.stack = i.stackcopy - error("$1:$2,$3 $4" % [i.currSym.filename, $i.currSym.line, $i.currSym.column, msg]) + i.error("$1:$2,$3 $4" % [i.currSym.filename, $i.currSym.line, $i.currSym.column, msg]) i.stackTrace() i.trace = @[] raise MinTrappedException(msg: msg)

@@ -429,4 +429,4 @@ proc parse*(i: In, s: string, name="<parse>"): MinValue =

return i.eval(s, name, true) proc read*(i: In, s: string): MinValue = - return i.load(s, true)+ return i.load(s, true)
M minpkg/lib/min_crypto.nimminpkg/lib/min_crypto.nim

@@ -1,6 +1,7 @@

import base64, strutils, + std/macros, times, ../vendor/aes/aes import

@@ -39,11 +40,11 @@

when defined(ssl): when defined(windows): - {.passL: "-static -Lminpkg/vendor/openssl/windows -lssl -lcrypto -lws2_32".} + {.passL: "-static -L"&getProjectPath()&"/minpkg/vendor/openssl/windows -lssl -lcrypto -lws2_32".} elif defined(linux): - {.passL: "-static -Lminpkg/vendor/openssl/linux -lssl -lcrypto".} + {.passL: "-static -L"&getProjectPath()&"/minpkg/vendor/openssl/linux -lssl -lcrypto".} elif defined(macosx): - {.passL: "-Bstatic -Lminpkg/vendor/openssl/macosx -lssl -lcrypto -Bdynamic".} + {.passL: "-Bstatic -L"&getProjectPath()&"/minpkg/vendor/openssl/macosx -lssl -lcrypto -Bdynamic".} proc hash(s: string, kind: EVP_MD, size: int): string = var hash_length: cuint = 0
M minpkg/lib/min_http.nimminpkg/lib/min_http.nim

@@ -1,4 +1,11 @@

-import httpclient, asynchttpserver, asyncdispatch, strutils, uri, critbits +import + std/macros, + httpclient, + asynchttpserver, + asyncdispatch, + strutils, + uri, + critbits import ../core/parser, ../core/meta,

@@ -8,11 +15,11 @@ ../core/utils

when defined(ssl) and defined(amd64): when defined(windows): - {.passL: "-static -Lminpkg/vendor/openssl/windows -lssl -lcrypto -lws2_32".} + {.passL: "-static -L"&getProjectPath()&"/minpkg/vendor/openssl/windows -lssl -lcrypto -lws2_32".} elif defined(linux): - {.passL: "-static -Lminpkg/vendor/openssl/linux -lssl -lcrypto".} + {.passL: "-static -L"&getProjectPath()&"/minpkg/vendor/openssl/linux -lssl -lcrypto".} elif defined(macosx): - {.passL: "-Bstatic -Lminpkg/vendor/openssl/macosx -lssl -lcrypto -Bdynamic".} + {.passL: "-Bstatic -L"&getProjectPath()&"/minpkg/vendor/openssl/macosx -lssl -lcrypto -Bdynamic".} var minUserAgent {.threadvar.} : string minUserAgent = "$1 http-module/$2" % [pkgName, pkgVersion]
M minpkg/lib/min_str.nimminpkg/lib/min_str.nim

@@ -2,6 +2,7 @@ import

strutils, sequtils, nre, + std/macros, uri import ../core/parser,

@@ -14,11 +15,11 @@ proc str_module*(i: In) =

let def = i.define() when defined(windows): - {.passL: "-static -Lminpkg/vendor/pcre/windows -lpcre".} + {.passL: "-static -L"&getProjectPath()&"/minpkg/vendor/pcre/windows -lpcre".} elif defined(linux): - {.passL: "-static -Lminpkg/vendor/pcre/linux -lpcre".} + {.passL: "-static -L"&getProjectPath()&"/minpkg/vendor/pcre/linux -lpcre".} elif defined(macosx): - {.passL: "-Bstatic -Lminpkg/vendor/pcre/macosx -lpcre -Bdynamic".} + {.passL: "-Bstatic -L"&getProjectPath()&"/minpkg/vendor/pcre/macosx -lpcre -Bdynamic".} def.symbol("interpolate") do (i: In): let vals = i.expect("quot", "str")