Re: [PATCH 2/5] config.mak.uname: supporting 64-bit MSys2

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

 



> This just makes things compile, the test suite needs extra tender loving
> care in addition to this change. We will address these issues in later
> commits.
> 
> While at it, also allow building MSys2 Git (i.e. a Git that uses MSys2's
> POSIX emulation layer).
> 
> Signed-off-by: Johannes Schindelin <johannes.schindelin@xxxxxx>
> ---
>  config.mak.uname | 14 +++++++++++---
>  1 file changed, 11 insertions(+), 3 deletions(-)
> 
> diff --git a/config.mak.uname b/config.mak.uname
> index b0592c1..4b2e1b8 100644
> --- a/config.mak.uname
> +++ b/config.mak.uname
> @@ -518,13 +518,12 @@ ifneq (,$(findstring MINGW,$(uname_S)))
>  	NO_INET_NTOP = YesPlease
>  	NO_POSIX_GOODIES = UnfortunatelyYes
>  	DEFAULT_HELP_FORMAT = html
> -	COMPAT_CFLAGS += -D_USE_32BIT_TIME_T -DNOGDI -Icompat -Icompat/win32
> +	COMPAT_CFLAGS += -DNOGDI -Icompat -Icompat/win32
>  	COMPAT_CFLAGS += -DSTRIP_EXTENSION=\".exe\"
>  	COMPAT_OBJS += compat/mingw.o compat/winansi.o \
>  		compat/win32/pthread.o compat/win32/syslog.o \
>  		compat/win32/dirent.o
>  	BASIC_CFLAGS += -DPROTECT_NTFS_DEFAULT=1
> -	BASIC_LDFLAGS += -Wl,--large-address-aware
>  	EXTLIBS += -lws2_32
>  	GITLIBS += git.res
>  	PTHREAD_LIBS =

(On Windows I only used git, and only briefly, and it was back in the
v1.9.x era, so please pardon my ignorance...)

I'm puzzled by the if statements in the hunk below:

> @@ -545,8 +544,17 @@ ifneq (,$(wildcard ../THIS_IS_MSYSGIT))
>  else
>  	ifeq ($(shell expr "$(uname_R)" : '2\.'),2)
>  		# MSys2
> +		prefix = /usr/
> +		ifeq (MINGW32,$(MSYSTEM))
> +			prefix = /mingw32

Here prefix is set for 32 bit MSys2.  OK.

> +		endif
> +		ifeq (MINGW64,$(MSYSTEM))
> +			prefix = /mingw64

Here prefix is set for 64 bit MSys2.  Still OK.

> +		else
> +			COMPAT_CFLAGS += -D_USE_32BIT_TIME_T
> +			BASIC_LDFLAGS += -Wl,--large-address-aware

But then these flags are set for any MSys2 that is not 64 bit, which
also includes MINGW32, which we've already dealt with above
explicitly.  Hmm.

Is this intentional?  It would be easier to follow if the settings
specific to MINGW32 weren't scattered in two discontinuous blocks.
What values can MSYSTEM have here besides MINGW32 and MINGW64?

Thanks,
Gábor

> +		endif
>  		CC = gcc
> -		prefix = /mingw32
>  		COMPAT_CFLAGS += -D__USE_MINGW_ANSI_STDIO=0
>  		INSTALL = /bin/install
>  		NO_R_TO_GCC_LINKER = YesPlease
> -- 
> 2.6.3.windows.1.300.g1c25e49

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