]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 9.1.0640: Mingw: Makefile can be improved v9.1.0640
authorKen Takata <kentkt@csc.jp>
Mon, 29 Jul 2024 18:43:21 +0000 (20:43 +0200)
committerChristian Brabandt <cb@256bit.org>
Mon, 29 Jul 2024 18:43:21 +0000 (20:43 +0200)
Problem:  Mingw: Makefile can be improved
Solution: Reduce nesting level, directly check if the '-Wl,--entry'
          option is required (Ken Takata)

closes: #15386

Signed-off-by: Ken Takata <kentkt@csc.jp>
Signed-off-by: Christian Brabandt <cb@256bit.org>
src/Make_cyg_ming.mak
src/version.c

index 7c324fb64f7720c76d4e2520bab9a5b5282f5934..d3b04e813a0b5a16a42cf1c5d597730c2b4a0ce4 100644 (file)
@@ -1140,15 +1140,14 @@ $(EXEOBJG): | $(OUTDIR)
 $(EXEOBJC): | $(OUTDIR)
 
 ifeq ($(VIMDLL),yes)
- ifneq ($(COVERAGE),yes)
-  ifndef MZSCHEME
-   ifeq ($(ARCH),x86-64)
+ ifneq ($(findstring -nostdlib,$(EXELFLAGS)),)
+  # -Wl,--entry needs to be specified when -nostdlib is used.
+  ifeq ($(ARCH),x86-64)
 EXEENTRYC = -Wl,--entry=wmainCRTStartup
 EXEENTRYG = -Wl,--entry=wWinMainCRTStartup
-   else ifeq ($(ARCH),i686)
+  else ifeq ($(ARCH),i686)
 EXEENTRYC = -Wl,--entry=_wmainCRTStartup
 EXEENTRYG = -Wl,--entry=_wWinMainCRTStartup@0
-   endif
   endif
  endif
 
index 97414a08a36f5cfbf23b2a990ca44468d0e9345b..53c1118937eb6041d5778488fa1e4577743aea01 100644 (file)
@@ -704,6 +704,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    640,
 /**/
     639,
 /**/