[apparmor] [patch] rename _clean to pod_clean in Makefiles

John Johansen john.johansen at canonical.com
Fri Jan 30 15:43:26 UTC 2015


On 01/28/2015 01:34 PM, Christian Boltz wrote:
> Hello,
> 
> since the Makefile cleanup, the _clean target is only used to delete 
> manpages etc. generated from *.pod files.
> 
is it? Sorry I haven't dug into this yet but from just looking at the
targets they list a lot more than pod files

So either we need to cleanup what is being done by these targets or
we should leave the name at clean, because pod_clean touching lib and
object files doesn't make any sense

> This patch renames the target to pod_clean to make it obvious what it 
> does.
> 
> 
> BTW: common/Make.rules uses "-rm -f" which means errors are ignored. 
> What's the reason for doing this? bzr blame isn't too useful - the line 
> was added in r516 (moved into Make.rules from various Makefiles), but 
> all those Makefiles used "rm -f" (without -), and there's no explanation 
> why the - was added.
> 
> 
> 
> [ Makefiles_pod_clean.diff ]
> 
> === modified file 'changehat/mod_apparmor/Makefile'
> --- changehat/mod_apparmor/Makefile     2015-01-23 23:52:09 +0000
> +++ changehat/mod_apparmor/Makefile     2015-01-28 21:22:45 +0000
> @@ -86,7 +86,7 @@
>         make install_manpages DESTDIR=${DESTDIR}
>  
>  .PHONY: clean
> -clean: _clean
> +clean: pod_clean
>         rm -rf .libs
>         rm -f *.la *.lo *.so *.o *.slo
some nice library files here

>  
> 
> === modified file 'common/Make.rules'
> --- common/Make.rules   2015-01-24 00:01:14 +0000
> +++ common/Make.rules   2015-01-28 21:22:10 +0000
> @@ -88,11 +88,11 @@
>  repo_version:
>          $(value REPO_VERSION_CMD)
>  
> -.PHONY: _clean
> +.PHONY: pod_clean
>  ifndef VERBOSE
> -.SILENT: _clean
> +.SILENT: pod_clean
>  endif
> -_clean:
> +pod_clean:
>         -rm -f ${MANPAGES} *.[0-9].gz ${HTMLMANPAGES} pod2htm*.tmp
>  
>  # =====================
> 
> === modified file 'deprecated/utils/Makefile'
> --- deprecated/utils/Makefile   2015-01-23 23:52:09 +0000
> +++ deprecated/utils/Makefile   2015-01-28 21:22:58 +0000
> @@ -50,7 +50,7 @@
>  ifndef VERBOSE
>  .SILENT: clean
>  endif
> -clean: _clean
> +clean: pod_clean
>         rm -f core core.* *.o *.s *.a *~
object and assembly files

>         rm -rf staging/ build/
>  
> 
> === modified file 'parser/Makefile'
> --- parser/Makefile     2015-01-23 23:52:09 +0000
> +++ parser/Makefile     2015-01-28 21:22:53 +0000
> @@ -355,7 +355,7 @@
>  .SILENT: clean
>  endif
>  .PHONY: clean
> -clean: _clean
> +clean: pod_clean
>         rm -f core core.* *.o *.s *.a *~ *.gcda *.gcno
more object, assembly, ...

>         rm -f gmon.out
>         rm -f $(TOOLS) $(TESTS)
> 
> === modified file 'utils/Makefile'
> --- utils/Makefile      2015-01-23 23:52:09 +0000
> +++ utils/Makefile      2015-01-28 21:22:36 +0000
> @@ -63,7 +63,7 @@
>  ifndef VERBOSE
>  .SILENT: clean
>  endif
> -clean: _clean
> +clean: pod_clean
>         rm -f core core.* *.o *.s *.a *~
object and assembly here as well

>         $(MAKE) -C po clean
>         $(MAKE) -C vim clean
> 
> === modified file 'utils/vim/Makefile'
> --- utils/vim/Makefile  2015-01-23 23:52:09 +0000
> +++ utils/vim/Makefile  2015-01-28 21:22:39 +0000
> @@ -25,5 +25,5 @@
>         #Testing with all pythons
>         $(call pyalldo, create-apparmor.vim.py > /dev/null)
>  
> -clean: _clean
> +clean: pod_clean
>         rm -f apparmor.vim
> 
> 
> 
> Regards,
> 
> Christian Boltz
> 




More information about the AppArmor mailing list