Re: [PATCH v2 2/2] sha1dc: optionally use sha1collisiondetection as a submodule

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

 



Ævar Arnfjörð Bjarmason  <avarab@xxxxxxxxx> writes:

> +# Define DC_SHA1_SUBMODULE in addition to DC_SHA1 to use the
> +# sha1collisiondetection shipped as a submodule instead of the
> +# non-submodule copy in sha1dc/. This is an experimental option used
> +# by the git project to migrate to using sha1collisiondetection as a
> +# submodule.
> +#

Yup, thanks.

I actually was envisioning something like this instead, though.

diff --git a/Makefile b/Makefile
index 6baad1669e..8d33936a12 100644
--- a/Makefile
+++ b/Makefile
@@ -989,6 +989,10 @@ EXTLIBS =
 
 GIT_USER_AGENT = git/$(GIT_VERSION)
 
+ifeq ($(wildcard sha1collisiondetection/lib/sha1.h),sha1collisiondetection/lib/sha1.h)
+DC_SHA1_SUBMODULE = auto
+endif
+
 include config.mak.uname
 -include config.mak.autogen
 -include config.mak

That way, a user can say "git submodule init/update" it to use it,
and deinit it to use the frozen version.

But when somebody (like me?) feels strongly enough, such a change
can always come on top of this patch, so let's have this
manual-configuration-only version as our first step.

Thanks.



[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]