Fossil SCM

For 32-bit MinGW compile: speed up zlib performance by using critical parts in optimized assembler (official zlib1.dll is compiled this way)

jan.nijtmans 2014-11-06 21:43 trunk
Commit 270897a3011424cfef1bd5d78dcc92d651131e49
+21 -10
--- src/makemake.tcl
+++ src/makemake.tcl
@@ -516,23 +516,28 @@
516516
ifndef MINGW_IS_32BIT_ONLY
517517
ifeq (,$(findstring w64-mingw32,$(PREFIX)))
518518
MINGW_IS_32BIT_ONLY = 1
519519
endif
520520
endif
521
-ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
522
-SSLCONFIG = mingw
523
-else
524
-SSLCONFIG = mingw64
525
-endif
526
-ifndef FOSSIL_ENABLE_MINIZ
527
-SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
528
-endif
529521
530522
#### The directories where the zlib include and library files are located.
531523
#
532524
ZINCDIR = $(SRCDIR)/../compat/zlib
533525
ZLIBDIR = $(SRCDIR)/../compat/zlib
526
+
527
+ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
528
+SSLCONFIG = mingw
529
+ZLIBCONFIG = LOC="-DASMV -DASMINF" OBJA="inffas86.o match.o"
530
+LIBTARGETS = $(ZLIBDIR)/inffas86.o $(ZLIBDIR)/match.o
531
+else
532
+SSLCONFIG = mingw64
533
+ZLIBCONFIG =
534
+LIBTARGETS =
535
+endif
536
+ifndef FOSSIL_ENABLE_MINIZ
537
+SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
538
+endif
534539
535540
#### The directories where the OpenSSL include and library files are located.
536541
# The recommended usage here is to use the Sysinternals junction tool
537542
# to create a hard link between an "openssl-1.x" sub-directory of the
538543
# Fossil source code directory and the target OpenSSL source directory.
@@ -774,11 +779,10 @@
774779
writeln -nonewline " \\\n \$(OBJDIR)/$s.o"
775780
}
776781
writeln "\n"
777782
writeln "APPNAME = ${name}.exe"
778783
writeln "APPTARGETS ="
779
-writeln "LIBTARGETS ="
780784
writeln {
781785
#### If the USE_WINDOWS variable exists, it is assumed that we are building
782786
# inside of a Windows-style shell; otherwise, it is assumed that we are
783787
# building inside of a Unix-style shell. Note that the "move" command is
784788
# broken when attempting to use it from the Windows shell via MinGW make
@@ -902,14 +906,21 @@
902906
$(OBJDIR)/cson_amalgamation.o
903907
}]
904908
905909
writeln {
906910
zlib:
907
- $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc libz.a
911
+ $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) $(ZLIBCONFIG) -f win32/Makefile.gcc libz.a
908912
909913
clean-zlib:
910914
$(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
915
+
916
+$(ZLIBDIR)/inffas86.o:
917
+ $(TCC) -c -o $@ -DASMINF -I$(ZLIBDIR) -O3 $(ZLIBDIR)/contrib/inflate86/inffas86.c
918
+
919
+$(ZLIBDIR)/match.o:
920
+ $(TCC) -c -o $@ -DASMV $(ZLIBDIR)/contrib/asm686/match.S
921
+
911922
912923
ifndef FOSSIL_ENABLE_MINIZ
913924
LIBTARGETS += zlib
914925
endif
915926
916927
--- src/makemake.tcl
+++ src/makemake.tcl
@@ -516,23 +516,28 @@
516 ifndef MINGW_IS_32BIT_ONLY
517 ifeq (,$(findstring w64-mingw32,$(PREFIX)))
518 MINGW_IS_32BIT_ONLY = 1
519 endif
520 endif
521 ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
522 SSLCONFIG = mingw
523 else
524 SSLCONFIG = mingw64
525 endif
526 ifndef FOSSIL_ENABLE_MINIZ
527 SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
528 endif
529
530 #### The directories where the zlib include and library files are located.
531 #
532 ZINCDIR = $(SRCDIR)/../compat/zlib
533 ZLIBDIR = $(SRCDIR)/../compat/zlib
 
 
 
 
 
 
 
 
 
 
 
 
 
534
535 #### The directories where the OpenSSL include and library files are located.
536 # The recommended usage here is to use the Sysinternals junction tool
537 # to create a hard link between an "openssl-1.x" sub-directory of the
538 # Fossil source code directory and the target OpenSSL source directory.
@@ -774,11 +779,10 @@
774 writeln -nonewline " \\\n \$(OBJDIR)/$s.o"
775 }
776 writeln "\n"
777 writeln "APPNAME = ${name}.exe"
778 writeln "APPTARGETS ="
779 writeln "LIBTARGETS ="
780 writeln {
781 #### If the USE_WINDOWS variable exists, it is assumed that we are building
782 # inside of a Windows-style shell; otherwise, it is assumed that we are
783 # building inside of a Unix-style shell. Note that the "move" command is
784 # broken when attempting to use it from the Windows shell via MinGW make
@@ -902,14 +906,21 @@
902 $(OBJDIR)/cson_amalgamation.o
903 }]
904
905 writeln {
906 zlib:
907 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc libz.a
908
909 clean-zlib:
910 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
 
 
 
 
 
 
 
911
912 ifndef FOSSIL_ENABLE_MINIZ
913 LIBTARGETS += zlib
914 endif
915
916
--- src/makemake.tcl
+++ src/makemake.tcl
@@ -516,23 +516,28 @@
516 ifndef MINGW_IS_32BIT_ONLY
517 ifeq (,$(findstring w64-mingw32,$(PREFIX)))
518 MINGW_IS_32BIT_ONLY = 1
519 endif
520 endif
 
 
 
 
 
 
 
 
521
522 #### The directories where the zlib include and library files are located.
523 #
524 ZINCDIR = $(SRCDIR)/../compat/zlib
525 ZLIBDIR = $(SRCDIR)/../compat/zlib
526
527 ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
528 SSLCONFIG = mingw
529 ZLIBCONFIG = LOC="-DASMV -DASMINF" OBJA="inffas86.o match.o"
530 LIBTARGETS = $(ZLIBDIR)/inffas86.o $(ZLIBDIR)/match.o
531 else
532 SSLCONFIG = mingw64
533 ZLIBCONFIG =
534 LIBTARGETS =
535 endif
536 ifndef FOSSIL_ENABLE_MINIZ
537 SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
538 endif
539
540 #### The directories where the OpenSSL include and library files are located.
541 # The recommended usage here is to use the Sysinternals junction tool
542 # to create a hard link between an "openssl-1.x" sub-directory of the
543 # Fossil source code directory and the target OpenSSL source directory.
@@ -774,11 +779,10 @@
779 writeln -nonewline " \\\n \$(OBJDIR)/$s.o"
780 }
781 writeln "\n"
782 writeln "APPNAME = ${name}.exe"
783 writeln "APPTARGETS ="
 
784 writeln {
785 #### If the USE_WINDOWS variable exists, it is assumed that we are building
786 # inside of a Windows-style shell; otherwise, it is assumed that we are
787 # building inside of a Unix-style shell. Note that the "move" command is
788 # broken when attempting to use it from the Windows shell via MinGW make
@@ -902,14 +906,21 @@
906 $(OBJDIR)/cson_amalgamation.o
907 }]
908
909 writeln {
910 zlib:
911 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) $(ZLIBCONFIG) -f win32/Makefile.gcc libz.a
912
913 clean-zlib:
914 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
915
916 $(ZLIBDIR)/inffas86.o:
917 $(TCC) -c -o $@ -DASMINF -I$(ZLIBDIR) -O3 $(ZLIBDIR)/contrib/inflate86/inffas86.c
918
919 $(ZLIBDIR)/match.o:
920 $(TCC) -c -o $@ -DASMV $(ZLIBDIR)/contrib/asm686/match.S
921
922
923 ifndef FOSSIL_ENABLE_MINIZ
924 LIBTARGETS += zlib
925 endif
926
927
+21 -10
--- win/Makefile.mingw
+++ win/Makefile.mingw
@@ -94,23 +94,28 @@
9494
ifndef MINGW_IS_32BIT_ONLY
9595
ifeq (,$(findstring w64-mingw32,$(PREFIX)))
9696
MINGW_IS_32BIT_ONLY = 1
9797
endif
9898
endif
99
-ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
100
-SSLCONFIG = mingw
101
-else
102
-SSLCONFIG = mingw64
103
-endif
104
-ifndef FOSSIL_ENABLE_MINIZ
105
-SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
106
-endif
10799
108100
#### The directories where the zlib include and library files are located.
109101
#
110102
ZINCDIR = $(SRCDIR)/../compat/zlib
111103
ZLIBDIR = $(SRCDIR)/../compat/zlib
104
+
105
+ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
106
+SSLCONFIG = mingw
107
+ZLIBCONFIG = LOC="-DASMV -DASMINF" OBJA="inffas86.o match.o"
108
+LIBTARGETS = $(ZLIBDIR)/inffas86.o $(ZLIBDIR)/match.o
109
+else
110
+SSLCONFIG = mingw64
111
+ZLIBCONFIG =
112
+LIBTARGETS =
113
+endif
114
+ifndef FOSSIL_ENABLE_MINIZ
115
+SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
116
+endif
112117
113118
#### The directories where the OpenSSL include and library files are located.
114119
# The recommended usage here is to use the Sysinternals junction tool
115120
# to create a hard link between an "openssl-1.x" sub-directory of the
116121
# Fossil source code directory and the target OpenSSL source directory.
@@ -677,11 +682,10 @@
677682
$(OBJDIR)/xfersetup.o \
678683
$(OBJDIR)/zip.o
679684
680685
APPNAME = fossil.exe
681686
APPTARGETS =
682
-LIBTARGETS =
683687
684688
#### If the USE_WINDOWS variable exists, it is assumed that we are building
685689
# inside of a Windows-style shell; otherwise, it is assumed that we are
686690
# building inside of a Unix-style shell. Note that the "move" command is
687691
# broken when attempting to use it from the Windows shell via MinGW make
@@ -802,14 +806,21 @@
802806
$(OBJDIR)/th_tcl.o \
803807
$(OBJDIR)/cson_amalgamation.o
804808
805809
806810
zlib:
807
- $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc libz.a
811
+ $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) $(ZLIBCONFIG) -f win32/Makefile.gcc libz.a
808812
809813
clean-zlib:
810814
$(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
815
+
816
+$(ZLIBDIR)/inffas86.o:
817
+ $(TCC) -c -o $@ -DASMINF -I$(ZLIBDIR) -O3 $(ZLIBDIR)/contrib/inflate86/inffas86.c
818
+
819
+$(ZLIBDIR)/match.o:
820
+ $(TCC) -c -o $@ -DASMV $(ZLIBDIR)/contrib/asm686/match.S
821
+
811822
812823
ifndef FOSSIL_ENABLE_MINIZ
813824
LIBTARGETS += zlib
814825
endif
815826
816827
--- win/Makefile.mingw
+++ win/Makefile.mingw
@@ -94,23 +94,28 @@
94 ifndef MINGW_IS_32BIT_ONLY
95 ifeq (,$(findstring w64-mingw32,$(PREFIX)))
96 MINGW_IS_32BIT_ONLY = 1
97 endif
98 endif
99 ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
100 SSLCONFIG = mingw
101 else
102 SSLCONFIG = mingw64
103 endif
104 ifndef FOSSIL_ENABLE_MINIZ
105 SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
106 endif
107
108 #### The directories where the zlib include and library files are located.
109 #
110 ZINCDIR = $(SRCDIR)/../compat/zlib
111 ZLIBDIR = $(SRCDIR)/../compat/zlib
 
 
 
 
 
 
 
 
 
 
 
 
 
112
113 #### The directories where the OpenSSL include and library files are located.
114 # The recommended usage here is to use the Sysinternals junction tool
115 # to create a hard link between an "openssl-1.x" sub-directory of the
116 # Fossil source code directory and the target OpenSSL source directory.
@@ -677,11 +682,10 @@
677 $(OBJDIR)/xfersetup.o \
678 $(OBJDIR)/zip.o
679
680 APPNAME = fossil.exe
681 APPTARGETS =
682 LIBTARGETS =
683
684 #### If the USE_WINDOWS variable exists, it is assumed that we are building
685 # inside of a Windows-style shell; otherwise, it is assumed that we are
686 # building inside of a Unix-style shell. Note that the "move" command is
687 # broken when attempting to use it from the Windows shell via MinGW make
@@ -802,14 +806,21 @@
802 $(OBJDIR)/th_tcl.o \
803 $(OBJDIR)/cson_amalgamation.o
804
805
806 zlib:
807 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc libz.a
808
809 clean-zlib:
810 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
 
 
 
 
 
 
 
811
812 ifndef FOSSIL_ENABLE_MINIZ
813 LIBTARGETS += zlib
814 endif
815
816
--- win/Makefile.mingw
+++ win/Makefile.mingw
@@ -94,23 +94,28 @@
94 ifndef MINGW_IS_32BIT_ONLY
95 ifeq (,$(findstring w64-mingw32,$(PREFIX)))
96 MINGW_IS_32BIT_ONLY = 1
97 endif
98 endif
 
 
 
 
 
 
 
 
99
100 #### The directories where the zlib include and library files are located.
101 #
102 ZINCDIR = $(SRCDIR)/../compat/zlib
103 ZLIBDIR = $(SRCDIR)/../compat/zlib
104
105 ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
106 SSLCONFIG = mingw
107 ZLIBCONFIG = LOC="-DASMV -DASMINF" OBJA="inffas86.o match.o"
108 LIBTARGETS = $(ZLIBDIR)/inffas86.o $(ZLIBDIR)/match.o
109 else
110 SSLCONFIG = mingw64
111 ZLIBCONFIG =
112 LIBTARGETS =
113 endif
114 ifndef FOSSIL_ENABLE_MINIZ
115 SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
116 endif
117
118 #### The directories where the OpenSSL include and library files are located.
119 # The recommended usage here is to use the Sysinternals junction tool
120 # to create a hard link between an "openssl-1.x" sub-directory of the
121 # Fossil source code directory and the target OpenSSL source directory.
@@ -677,11 +682,10 @@
682 $(OBJDIR)/xfersetup.o \
683 $(OBJDIR)/zip.o
684
685 APPNAME = fossil.exe
686 APPTARGETS =
 
687
688 #### If the USE_WINDOWS variable exists, it is assumed that we are building
689 # inside of a Windows-style shell; otherwise, it is assumed that we are
690 # building inside of a Unix-style shell. Note that the "move" command is
691 # broken when attempting to use it from the Windows shell via MinGW make
@@ -802,14 +806,21 @@
806 $(OBJDIR)/th_tcl.o \
807 $(OBJDIR)/cson_amalgamation.o
808
809
810 zlib:
811 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) $(ZLIBCONFIG) -f win32/Makefile.gcc libz.a
812
813 clean-zlib:
814 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
815
816 $(ZLIBDIR)/inffas86.o:
817 $(TCC) -c -o $@ -DASMINF -I$(ZLIBDIR) -O3 $(ZLIBDIR)/contrib/inflate86/inffas86.c
818
819 $(ZLIBDIR)/match.o:
820 $(TCC) -c -o $@ -DASMV $(ZLIBDIR)/contrib/asm686/match.S
821
822
823 ifndef FOSSIL_ENABLE_MINIZ
824 LIBTARGETS += zlib
825 endif
826
827
--- win/Makefile.mingw.mistachkin
+++ win/Makefile.mingw.mistachkin
@@ -46,11 +46,11 @@
4646
#
4747
FOSSIL_ENABLE_JSON = 1
4848
4949
#### Enable HTTPS support via OpenSSL (links to libssl and libcrypto)
5050
#
51
-FOSSIL_ENABLE_SSL = 1
51
+# FOSSIL_ENABLE_SSL = 1
5252
5353
#### Automatically build OpenSSL when building Fossil (causes rebuild
5454
# issues when building incrementally).
5555
#
5656
# FOSSIL_BUILD_SSL = 1
@@ -94,23 +94,28 @@
9494
ifndef MINGW_IS_32BIT_ONLY
9595
ifeq (,$(findstring w64-mingw32,$(PREFIX)))
9696
MINGW_IS_32BIT_ONLY = 1
9797
endif
9898
endif
99
-ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
100
-SSLCONFIG = mingw
101
-else
102
-SSLCONFIG = mingw64
103
-endif
104
-ifndef FOSSIL_ENABLE_MINIZ
105
-SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
106
-endif
10799
108100
#### The directories where the zlib include and library files are located.
109101
#
110102
ZINCDIR = $(SRCDIR)/../compat/zlib
111103
ZLIBDIR = $(SRCDIR)/../compat/zlib
104
+
105
+ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
106
+SSLCONFIG = mingw
107
+ZLIBCONFIG = LOC="-DASMV -DASMINF" OBJA="inffas86.o match.o"
108
+LIBTARGETS = $(ZLIBDIR)/inffas86.o $(ZLIBDIR)/match.o
109
+else
110
+SSLCONFIG = mingw64
111
+ZLIBCONFIG =
112
+LIBTARGETS =
113
+endif
114
+ifndef FOSSIL_ENABLE_MINIZ
115
+SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
116
+endif
112117
113118
#### The directories where the OpenSSL include and library files are located.
114119
# The recommended usage here is to use the Sysinternals junction tool
115120
# to create a hard link between an "openssl-1.x" sub-directory of the
116121
# Fossil source code directory and the target OpenSSL source directory.
@@ -677,11 +682,10 @@
677682
$(OBJDIR)/xfersetup.o \
678683
$(OBJDIR)/zip.o
679684
680685
APPNAME = fossil.exe
681686
APPTARGETS =
682
-LIBTARGETS =
683687
684688
#### If the USE_WINDOWS variable exists, it is assumed that we are building
685689
# inside of a Windows-style shell; otherwise, it is assumed that we are
686690
# building inside of a Unix-style shell. Note that the "move" command is
687691
# broken when attempting to use it from the Windows shell via MinGW make
@@ -802,14 +806,21 @@
802806
$(OBJDIR)/th_tcl.o \
803807
$(OBJDIR)/cson_amalgamation.o
804808
805809
806810
zlib:
807
- $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc libz.a
811
+ $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) $(ZLIBCONFIG) -f win32/Makefile.gcc libz.a
808812
809813
clean-zlib:
810814
$(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
815
+
816
+$(ZLIBDIR)/inffas86.o:
817
+ $(TCC) -c -o $@ -DASMINF -I$(ZLIBDIR) -O3 $(ZLIBDIR)/contrib/inflate86/inffas86.c
818
+
819
+$(ZLIBDIR)/match.o:
820
+ $(TCC) -c -o $@ -DASMV $(ZLIBDIR)/contrib/asm686/match.S
821
+
811822
812823
ifndef FOSSIL_ENABLE_MINIZ
813824
LIBTARGETS += zlib
814825
endif
815826
816827
--- win/Makefile.mingw.mistachkin
+++ win/Makefile.mingw.mistachkin
@@ -46,11 +46,11 @@
46 #
47 FOSSIL_ENABLE_JSON = 1
48
49 #### Enable HTTPS support via OpenSSL (links to libssl and libcrypto)
50 #
51 FOSSIL_ENABLE_SSL = 1
52
53 #### Automatically build OpenSSL when building Fossil (causes rebuild
54 # issues when building incrementally).
55 #
56 # FOSSIL_BUILD_SSL = 1
@@ -94,23 +94,28 @@
94 ifndef MINGW_IS_32BIT_ONLY
95 ifeq (,$(findstring w64-mingw32,$(PREFIX)))
96 MINGW_IS_32BIT_ONLY = 1
97 endif
98 endif
99 ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
100 SSLCONFIG = mingw
101 else
102 SSLCONFIG = mingw64
103 endif
104 ifndef FOSSIL_ENABLE_MINIZ
105 SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
106 endif
107
108 #### The directories where the zlib include and library files are located.
109 #
110 ZINCDIR = $(SRCDIR)/../compat/zlib
111 ZLIBDIR = $(SRCDIR)/../compat/zlib
 
 
 
 
 
 
 
 
 
 
 
 
 
112
113 #### The directories where the OpenSSL include and library files are located.
114 # The recommended usage here is to use the Sysinternals junction tool
115 # to create a hard link between an "openssl-1.x" sub-directory of the
116 # Fossil source code directory and the target OpenSSL source directory.
@@ -677,11 +682,10 @@
677 $(OBJDIR)/xfersetup.o \
678 $(OBJDIR)/zip.o
679
680 APPNAME = fossil.exe
681 APPTARGETS =
682 LIBTARGETS =
683
684 #### If the USE_WINDOWS variable exists, it is assumed that we are building
685 # inside of a Windows-style shell; otherwise, it is assumed that we are
686 # building inside of a Unix-style shell. Note that the "move" command is
687 # broken when attempting to use it from the Windows shell via MinGW make
@@ -802,14 +806,21 @@
802 $(OBJDIR)/th_tcl.o \
803 $(OBJDIR)/cson_amalgamation.o
804
805
806 zlib:
807 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc libz.a
808
809 clean-zlib:
810 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
 
 
 
 
 
 
 
811
812 ifndef FOSSIL_ENABLE_MINIZ
813 LIBTARGETS += zlib
814 endif
815
816
--- win/Makefile.mingw.mistachkin
+++ win/Makefile.mingw.mistachkin
@@ -46,11 +46,11 @@
46 #
47 FOSSIL_ENABLE_JSON = 1
48
49 #### Enable HTTPS support via OpenSSL (links to libssl and libcrypto)
50 #
51 # FOSSIL_ENABLE_SSL = 1
52
53 #### Automatically build OpenSSL when building Fossil (causes rebuild
54 # issues when building incrementally).
55 #
56 # FOSSIL_BUILD_SSL = 1
@@ -94,23 +94,28 @@
94 ifndef MINGW_IS_32BIT_ONLY
95 ifeq (,$(findstring w64-mingw32,$(PREFIX)))
96 MINGW_IS_32BIT_ONLY = 1
97 endif
98 endif
 
 
 
 
 
 
 
 
99
100 #### The directories where the zlib include and library files are located.
101 #
102 ZINCDIR = $(SRCDIR)/../compat/zlib
103 ZLIBDIR = $(SRCDIR)/../compat/zlib
104
105 ifeq (,$(findstring x86_64-w64-mingw32,$(PREFIX)))
106 SSLCONFIG = mingw
107 ZLIBCONFIG = LOC="-DASMV -DASMINF" OBJA="inffas86.o match.o"
108 LIBTARGETS = $(ZLIBDIR)/inffas86.o $(ZLIBDIR)/match.o
109 else
110 SSLCONFIG = mingw64
111 ZLIBCONFIG =
112 LIBTARGETS =
113 endif
114 ifndef FOSSIL_ENABLE_MINIZ
115 SSLCONFIG += --with-zlib-lib=$(PWD)/$(ZLIBDIR) --with-zlib-include=$(PWD)/$(ZLIBDIR) zlib
116 endif
117
118 #### The directories where the OpenSSL include and library files are located.
119 # The recommended usage here is to use the Sysinternals junction tool
120 # to create a hard link between an "openssl-1.x" sub-directory of the
121 # Fossil source code directory and the target OpenSSL source directory.
@@ -677,11 +682,10 @@
682 $(OBJDIR)/xfersetup.o \
683 $(OBJDIR)/zip.o
684
685 APPNAME = fossil.exe
686 APPTARGETS =
 
687
688 #### If the USE_WINDOWS variable exists, it is assumed that we are building
689 # inside of a Windows-style shell; otherwise, it is assumed that we are
690 # building inside of a Unix-style shell. Note that the "move" command is
691 # broken when attempting to use it from the Windows shell via MinGW make
@@ -802,14 +806,21 @@
806 $(OBJDIR)/th_tcl.o \
807 $(OBJDIR)/cson_amalgamation.o
808
809
810 zlib:
811 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) $(ZLIBCONFIG) -f win32/Makefile.gcc libz.a
812
813 clean-zlib:
814 $(MAKE) -C $(ZLIBDIR) PREFIX=$(PREFIX) -f win32/Makefile.gcc clean
815
816 $(ZLIBDIR)/inffas86.o:
817 $(TCC) -c -o $@ -DASMINF -I$(ZLIBDIR) -O3 $(ZLIBDIR)/contrib/inflate86/inffas86.c
818
819 $(ZLIBDIR)/match.o:
820 $(TCC) -c -o $@ -DASMV $(ZLIBDIR)/contrib/asm686/match.S
821
822
823 ifndef FOSSIL_ENABLE_MINIZ
824 LIBTARGETS += zlib
825 endif
826
827

Keyboard Shortcuts

Open search /
Next entry (timeline) j
Previous entry (timeline) k
Open focused entry Enter
Show this help ?
Toggle theme Top nav button