Flutter + flake + direnv: can't compile flutter project due to spaces in path

Basically, I have a folder that has a space in its path, and I have a flake for a flutter project I have, and it does not want to build. It fails with:

CMake Error at /nix/store/hkhmxs4n1agpdpyamlh2b78pm9wch0br-cmake-3.27.9/share/cmake-3.27/Modules/CMakeTestCXXCompiler.cmake:60 (message):
  The C++ compiler

    "/nix/store/09n3varkcqmpnwklmr5db2xj50ilm5h8-clang-wrapper-17.0.6/bin/clang++"

  is not able to compile a simple test program.

  It fails with the following output:

    Change Dir: '/home/stereomato/Documents/Software Development/Repositories/Personal/spm_gui/spm_gui/build/linux/x64/debug/CMakeFiles/CMakeScratch/TryCompile-or7C72'

    Run Build Command(s): /nix/store/0xns1gyza3sm938pc7klvzrjk5iqam9l-ninja-1.11.1/bin/ninja -v cmTC_d27c2
    [1/2] /nix/store/09n3varkcqmpnwklmr5db2xj50ilm5h8-clang-wrapper-17.0.6/bin/clang++   -isystem /nix/store/lclgl38fv2iy17hych4b1135znyb4cqv-libX11-1.8.7-dev/include -isystem /nix/store/1n9gzxvlbiihbqlz9rq24xw9h71k9rnc-xorgproto-2023.2/include -isystem /nix/store/fhrwzmzvkj5yjsb4mb37w6smbg6banrs-zlib-1.3.1-dev/include -MD -MT CMakeFiles/cmTC_d27c2.dir/testCXXCompiler.cxx.o -MF CMakeFiles/cmTC_d27c2.dir/testCXXCompiler.cxx.o.d -o CMakeFiles/cmTC_d27c2.dir/testCXXCompiler.cxx.o -c '/home/stereomato/Documents/Software Development/Repositories/Personal/spm_gui/spm_gui/build/linux/x64/debug/CMakeFiles/CMakeScratch/TryCompile-or7C72/testCXXCompiler.cxx'
    [2/2] : && /nix/store/09n3varkcqmpnwklmr5db2xj50ilm5h8-clang-wrapper-17.0.6/bin/clang++ -isystem /nix/store/lclgl38fv2iy17hych4b1135znyb4cqv-libX11-1.8.7-dev/include -isystem /nix/store/1n9gzxvlbiihbqlz9rq24xw9h71k9rnc-xorgproto-2023.2/include -isystem /nix/store/fhrwzmzvkj5yjsb4mb37w6smbg6banrs-zlib-1.3.1-dev/include -Wl,-rpath,/nix/store/cwxdcqv8yq7v5xjrqp30f73rp3ibl8iw-at-spi2-core-2.50.0/lib -Wl,-rpath,/nix/store/1dp5ic3d61iggavkgnyh9fvsys50h6lc-cairo-1.18.0/lib -Wl,-rpath,/nix/store/gw95v3bssdf1r1p3cm1dvdq0rpzcgak8-gdk-pixbuf-2.42.10/lib -Wl,-rpath,/nix/store/hbdl12ck2ibhn5zsi8nsfa6v471pf0j6-glib-2.78.4/lib -Wl,-rpath,/nix/store/rp383l10xlx4l8mqjk98zd2x8q0ilk7r-gtk+3-3.24.39/lib -Wl,-rpath,/nix/store/649pkpdac5530v3lhq5wh9gvz9ff698q-harfbuzz-7.3.0/lib -Wl,-rpath,/nix/store/p74vc5hcxb0fjcc6av251d7pngfj7dgk-libepoxy-1.5.10/lib -Wl,-rpath,/nix/store/6grs6ljgh3a1z2g3gc0m8imhgqh4nq54-pango-1.51.0/lib -Wl,-rpath,/nix/store/ga17mlfsss2fndyvp2s1m0s2rx2b4i9s-libX11-1.8.7/lib -Wl,-rpath,/nix/store/frwal1lffq0gyfvz69npi7rcc6zhbwfg-libdeflate-1.19/lib CMakeFiles/cmTC_d27c2.dir/testCXXCompiler.cxx.o -o cmTC_d27c2   && :
    FAILED: cmTC_d27c2 
    : && /nix/store/09n3varkcqmpnwklmr5db2xj50ilm5h8-clang-wrapper-17.0.6/bin/clang++ -isystem /nix/store/lclgl38fv2iy17hych4b1135znyb4cqv-libX11-1.8.7-dev/include -isystem /nix/store/1n9gzxvlbiihbqlz9rq24xw9h71k9rnc-xorgproto-2023.2/include -isystem /nix/store/fhrwzmzvkj5yjsb4mb37w6smbg6banrs-zlib-1.3.1-dev/include -Wl,-rpath,/nix/store/cwxdcqv8yq7v5xjrqp30f73rp3ibl8iw-at-spi2-core-2.50.0/lib -Wl,-rpath,/nix/store/1dp5ic3d61iggavkgnyh9fvsys50h6lc-cairo-1.18.0/lib -Wl,-rpath,/nix/store/gw95v3bssdf1r1p3cm1dvdq0rpzcgak8-gdk-pixbuf-2.42.10/lib -Wl,-rpath,/nix/store/hbdl12ck2ibhn5zsi8nsfa6v471pf0j6-glib-2.78.4/lib -Wl,-rpath,/nix/store/rp383l10xlx4l8mqjk98zd2x8q0ilk7r-gtk+3-3.24.39/lib -Wl,-rpath,/nix/store/649pkpdac5530v3lhq5wh9gvz9ff698q-harfbuzz-7.3.0/lib -Wl,-rpath,/nix/store/p74vc5hcxb0fjcc6av251d7pngfj7dgk-libepoxy-1.5.10/lib -Wl,-rpath,/nix/store/6grs6ljgh3a1z2g3gc0m8imhgqh4nq54-pango-1.51.0/lib -Wl,-rpath,/nix/store/ga17mlfsss2fndyvp2s1m0s2rx2b4i9s-libX11-1.8.7/lib -Wl,-rpath,/nix/store/frwal1lffq0gyfvz69npi7rcc6zhbwfg-libdeflate-1.19/lib CMakeFiles/cmTC_d27c2.dir/testCXXCompiler.cxx.o -o cmTC_d27c2   && :
    /nix/store/2ab5740x0cy1d74qvbpl5s28qikmppl5-binutils-2.40/bin/ld: cannot find Development/Repositories/Personal/spm_gui/spm_gui/outputs/out/lib: No such file or directory
    clang++: error: linker command failed with exit code 1 (use -v to see invocation)
    ninja: build stopped: subcommand failed.

Now, the thing that has said path mentioned is NIX_LDFLAGS, and indeed, the path is there, not escaped or quoted (but even adding single quotes doesn’t help). I don’t know what to do, should I just NOT use paths with spaces here? I feel something is weird along the chain but no idea where…