# \`make cleanall\` breaks \`make\`?

**URL:** <https://discourse.julialang.org/t/make-cleanall-breaks-make/102009>\
**Category:** Internals & Design\
**Created:** [July 24, 2023, 11:53am UTC](https://discourse.julialang.org/t/make-cleanall-breaks-make/102009 "2023-07-24T11:53:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![nsajko](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nsajko/32/221187_2.png) [@nsajko](https://discourse.julialang.org/u/nsajko)\
**Post date:** [July 24, 2023, 11:53am UTC](https://discourse.julialang.org/t/make-cleanall-breaks-make/102009/1 "2023-07-24T11:53:04Z")

</div>

While hacking on Julia Base, I ran `make`, which resulted in an error during bootstrap, and suggested I run `make clean` and `make cleanall`. I did that, the problem now is that `make` doesn’t work any more after `make cleanall`, and I’m not sure how to fix this.

After switching back to the `master` branch:

```julia
$ make
make[2]: *** No rule to make target '/home/nsajko/tmp/julia/deps/srccache/patchelf-0.13/Makefile.am', needed by '/home/nsajko/tmp/julia/deps/srccache/patchelf-0.13/Makefile.in'. Stop.
make[1]: *** [/home/nsajko/tmp/jl/jl/julia/deps/patchelf.mk:39: /home/nsajko/tmp/jl/jl/julia/usr-staging/patchelf-0.13.tar] Error 2
make: *** [Makefile:75: julia-deps] Error 2

```

Any ideas for being able to build Julia again from this local repo?

---

<div class="post-metadata">

**Author:** ![nsajko](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nsajko/32/221187_2.png) [@nsajko](https://discourse.julialang.org/u/nsajko)\
**Post date:** [July 24, 2023, 11:58am UTC](https://discourse.julialang.org/t/make-cleanall-breaks-make/102009/2 "2023-07-24T11:58:15Z")

</div>

After deleting `deps/srccache` and re-running `make` I get:

```julia
...
Making all in src
make[3]: *** No rule to make target '/home/nsajko/tmp/julia/deps/srccache/patchelf-0.13/src/patchelf.cc', needed by 'patchelf.o'. Stop.
make[2]: *** [Makefile:439: all-recursive] Error 1
make[1]: *** [/home/nsajko/tmp/jl/jl/julia/deps/patchelf.mk:27: scratch/patchelf-0.13/build-compiled] Error 2
make: *** [Makefile:75: julia-deps] Error 2

```

---

<div class="post-metadata">

**Author:** ![nsajko](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nsajko/32/221187_2.png) [@nsajko](https://discourse.julialang.org/u/nsajko)\
**Post date:** [July 24, 2023, 2:02pm UTC](https://discourse.julialang.org/t/make-cleanall-breaks-make/102009/3 "2023-07-24T14:02:37Z")

</div>

Seems that it’s fixed after

```sh
rm -r -f deps/srccache/ deps/scratch/
make clean
make

```
