mirror of
https://git.FreeBSD.org/ports.git
synced 2024-11-30 01:15:52 +00:00
9b2aa8fa5e
Nimrod is a statically typed, imperative programming language. Beneath a nice infix/indentation based syntax with a powerful macro system lies a semantic model that supports a soft realtime GC on thread local heaps. Asynchronous message passing is used between threads. PR: ports/174368 Submitted by: Neal Nelson <ports@nicandneal.net>
26 lines
1013 B
Nim
26 lines
1013 B
Nim
--- compiler/nimconf.nim.orig
|
|
+++ compiler/nimconf.nim
|
|
@@ -213,7 +213,9 @@
|
|
proc getSystemConfigPath(filename: string): string =
|
|
# try standard configuration file (installation did not distribute files
|
|
# the UNIX way)
|
|
- result = joinPath([getPrefixDir(), "config", filename])
|
|
+ var prefix = getPrefixDir()
|
|
+ result = joinPath([prefix, "etc", filename])
|
|
+ if not ExistsFile(result): result = joinPath([prefix, "config", filename])
|
|
if not ExistsFile(result): result = "/etc/" & filename
|
|
|
|
proc LoadConfigs*(cfg: string) =
|
|
@@ -221,9 +223,8 @@
|
|
if libpath == "":
|
|
# choose default libpath:
|
|
var prefix = getPrefixDir()
|
|
- if prefix == "/usr": libpath = "/usr/lib/nimrod"
|
|
- elif prefix == "/usr/local": libpath = "/usr/local/lib/nimrod"
|
|
- else: libpath = joinPath(prefix, "lib")
|
|
+ libpath = joinPath(prefix, "lib/nimrod")
|
|
+ if not ExistsDir(libpath): libpath = joinPath(prefix, "lib")
|
|
|
|
if optSkipConfigFile notin gGlobalOptions:
|
|
readConfigFile(getSystemConfigPath(cfg))
|