Re: [PATCH] NO_PERL support

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



"Robin H. Johnson" <robbat2@xxxxxxxxxx> writes:

> diff --git a/Makefile b/Makefile
> index 0675c43..0adb2b5 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -139,6 +139,8 @@ all::
>  # Define NO_PERL_MAKEMAKER if you cannot use Makefiles generated by perl's
>  # MakeMaker (e.g. using ActiveState under Cygwin).
>  #
> +# Define NO_PERL if you do not want Perl scripts at all.
> +#
>  # Define NO_TCLTK if you do not want Tcl/Tk GUI.
>  #
>  # The TCL_PATH variable governs the location of the Tcl interpreter
> @@ -277,6 +279,8 @@ SCRIPT_SH += git-stash.sh
>  SCRIPT_SH += git-submodule.sh
>  SCRIPT_SH += git-web--browse.sh
>  
> +SCRIPTS = $(patsubst %.sh,%,$(SCRIPT_SH))
> +ifndef NO_PERL
>  SCRIPT_PERL += git-add--interactive.perl
>  SCRIPT_PERL += git-archimport.perl
>  SCRIPT_PERL += git-cvsexportcommit.perl
> @@ -285,10 +289,11 @@ SCRIPT_PERL += git-cvsserver.perl
>  SCRIPT_PERL += git-relink.perl
>  SCRIPT_PERL += git-send-email.perl
>  SCRIPT_PERL += git-svn.perl
> -
> -SCRIPTS = $(patsubst %.sh,%,$(SCRIPT_SH)) \
> -	  $(patsubst %.perl,%,$(SCRIPT_PERL)) \
> -	  git-instaweb
> +SCRIPTS += $(patsubst %.perl,%,$(SCRIPT_PERL)) \
> +			git-instaweb
> +else
> +SCRIPT_PERL =
> +endif
>  
>...
> +ifdef NO_PERL
> +	BASIC_CFLAGS += -DNO_PERL
> +endif

While I do not mind omitting whole programs in fringes like you did for
archimport and relink, I *really* do not like this particular change (and
any change to the C code).

I'd rather see something along the lines of:

	if NO_PERL
        git-add--interactive: unimplemented.sh
        	rm -f $@+ $@
                cat $? >$@+
                chmod +x $@+
                mv $@+ $@
	else
        git-add--interactive: git-add--interactive.perl
        	... usual .perl to script rule applies
	endif

and ship:

	#!/bin/sh
        echo >&2 "Sorry $0 not available here"
        exit 1

in unimplemented.sh, *without* touching code that calls out to
scripts that happen to be implemented in Perl.
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux