From 0c9685d1360098606cc11b6b5168b3fc9401e2fc Mon Sep 17 00:00:00 2001 From: Matthew Flatt Date: Wed, 30 Apr 2014 13:49:17 -0600 Subject: [PATCH] raco exe: normalize runtime-file paths Normalization is needed to ensure that `raco dist` doesn't generate longer paths (by converting a "/" to "\\", for example) in its path manipulations. --- racket/collects/compiler/embed.rkt | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/racket/collects/compiler/embed.rkt b/racket/collects/compiler/embed.rkt index 6189c5b805..776da76e5e 100644 --- a/racket/collects/compiler/embed.rkt +++ b/racket/collects/compiler/embed.rkt @@ -1188,10 +1188,11 @@ (and p (if (symbol? p) p - (path->bytes - (if (absolute-path? p) - p - (build-path (path-only (mod-file nc)) p)))))) + (path->bytes + (simplify-path + (if (absolute-path? p) + p + (build-path (path-only (mod-file nc)) p))))))) ;; As for the extension table, a placeholder to save ;; room likely needed by the distribution-mangler. ;; The extra "."s are meant to cover the relative