# make fetch, but skip broken ports



## int19h (Sep 19, 2017)

When running make fetch over a category, is there any way to tell it to skip any ports that are marked as broken? E.g. doing it for astro right now, you immediately run into this:

https://forums.freebsd.org/threads/58827/


----------



## SirDice (Sep 19, 2017)

Why on earth would you want to fetch _everything_? There are close to 31500 ports, so that's a lot of data, most of it is probably never going to get used (I very much doubt you're going to install _everything_).


----------



## tobik@ (Sep 19, 2017)

int19h said:


> When running make fetch over a category, is there any way to tell it to skip any ports that are marked as broken?


I don't think so, but you could create /usr/ports/astro/Makefile.local with 
	
	



```
SUBDIR:=	${SUBDIR:Ngmapcatcher:Nviking}
```
 to exclude specific ports.

You can always try `make -DTRYBROKEN fetch` but there is no guarantee that the distfiles of broken ports can be fetched.


----------



## int19h (Sep 26, 2017)

Thanks! This works to the extent that some ports marked as broken due to Google Code being down then fetch distfiles from FreeBSD mirror. But some don't. I ended up just writing a script that walks the tree and invokes make fetch recursively, ignoring errors.

As far as why - think of an offline distfiles cache, shared and/or distributed on USB sticks etc. The size is manageable - I did a very similar thing for Arch Linux before, and it added up to less than 60 GB of files - a perfect fit for your typical 64 GB stick or SD card.


----------

