Conditionally define vars to improve portability

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

 



Default variables used to build are set using = on Makefile, (e.g. CC, INSTALL, CFLAGS, …). GNU make overwrite these values if it’s passed as an argument (make CC=clang) and it works as expected.

Default method of passing arguments for make operations on FreeBSD ports tree is using environment variables instead of make arguments, then we have CC set on env before call gmake. Today these values are ignored by git Makefile, and we ended up patching Makefile replacing = by ?= on variable assignments [1].

Before I write a patch and submit I would like to check if it would be an acceptable change of if it’s something you won’t accept for any reason.

Regards

[1] https://svnweb.freebsd.org/ports/head/devel/git/files/patch-Makefile?revision=396048&view=markup#l7
--
Renato Botelho

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