@@ -891,12 +891,12 @@ func (d *Devbox) computeNixEnv(ctx context.Context, usePrintDevEnvCache bool) (m
891
891
// Motivation: if a user removes a package from their devbox it should no longer
892
892
// be available in their environment.
893
893
buildInputs := strings .Split (env ["buildInputs" ], " " )
894
- glibcPatchPath := ""
894
+ var glibcPatchPath [] string
895
895
nixEnvPath = filterPathList (nixEnvPath , func (path string ) bool {
896
896
// TODO(gcurtis): this is a massive hack. Please get rid
897
897
// of this and install the package to the profile.
898
898
if strings .Contains (path , "patched-glibc" ) {
899
- glibcPatchPath = path
899
+ glibcPatchPath = append ( glibcPatchPath , path )
900
900
return true
901
901
}
902
902
for _ , input := range buildInputs {
@@ -913,8 +913,9 @@ func (d *Devbox) computeNixEnv(ctx context.Context, usePrintDevEnvCache bool) (m
913
913
914
914
// TODO(gcurtis): this is a massive hack. Please get rid
915
915
// of this and install the package to the profile.
916
- if glibcPatchPath != "" {
917
- nixEnvPath = glibcPatchPath + ":" + nixEnvPath
916
+ if len (glibcPatchPath ) != 0 {
917
+ patchedPath := strings .Join (glibcPatchPath , string (filepath .ListSeparator ))
918
+ nixEnvPath = envpath .JoinPathLists (patchedPath , nixEnvPath )
918
919
debug .Log ("PATH after glibc-patch hack is: %s" , nixEnvPath )
919
920
}
920
921
0 commit comments