Skip to content

Commit 909d4d1

Browse files
authored
Merge pull request #3057 from owasp-modsecurity/revert-2931-leancz-patch-1-pcre2-windows
Revert "Adding PCRE2 support for windows build in Makefile.win"
2 parents 7b031b6 + b124641 commit 909d4d1

File tree

1 file changed

+14
-27
lines changed

1 file changed

+14
-27
lines changed

apache2/Makefile.win

Lines changed: 14 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,37 +1,29 @@
11
###########################################################################
22
#
3-
# Usage: NMAKE -f Makefile.win APACHE={httpd installion dir} PCRE|PCRE2={pcre dir} LIBXML2={LibXML2 dir} [ LUA={Lua dir} ]
3+
# Usage: NMAKE -f Makefile.win APACHE={httpd installion dir} PCRE={pcre dir} LIBXML2={LibXML2 dir} [ LUA={Lua dir} ]
44
#
5-
!IF "$(PCRE2)" != ""
6-
PCRE = $(PCRE2)
7-
!ENDIF
8-
95
!IF "$(APACHE)" == "" || "$(PCRE)" == "" || "$(LIBXML2)" == "" || "$(CURL)" == ""
10-
!ERROR NMAKE arguments: APACHE=dir PCRE|PCRE2=dir LIBXML2=dir CURL=dir are required to build mod_security2 for Windows
6+
!ERROR NMAKE arguments: APACHE=dir PCRE=dir LIBXML2=dir CURL=dir are required to build mod_security2 for Windows
117
!ENDIF
128

139
# Linking libraries
1410
LIBS = $(APACHE)\lib\libhttpd.lib \
1511
$(APACHE)\lib\libapr-1.lib \
1612
$(APACHE)\lib\libaprutil-1.lib \
17-
$(CURL)\libcurl.lib \
13+
$(PCRE)\pcre.lib \
14+
$(CURL)\libcurl.lib \
1815
$(LIBXML2)\win32\bin.msvc\libxml2.lib \
1916
Ws2_32.lib \
2017
"iphlpapi.lib"
2118

22-
!IF "$(PCRE2)" != ""
23-
LIBS =$(LIBS) $(PCRE2)\lib\pcre2-8.lib
24-
!ELSE
25-
LIBS =$(LIBS) $(PCRE)\lib\pcre.lib
26-
!ENDIF
2719
###########################################################################
2820
###########################################################################
2921

30-
31-
!IF "$(IIS_BUILD)" == "yes"
32-
DEFS=$(DEFS) -DVERSION_IIS
33-
!ENDIF
34-
22+
23+
!IF "$(IIS_BUILD)" == "yes"
24+
DEFS=$(DEFS) -DVERSION_IIS
25+
!ENDIF
26+
3527
CC = CL
3628

3729
MT = mt
@@ -45,14 +37,9 @@ INCLUDES = -I. -I.. \
4537
-I$(PCRE)\include -I$(PCRE) \
4638
-I$(LIBXML2)\include \
4739
-I$(APACHE)\include
48-
49-
# Enables support for SecRemoteRules and external resources.
50-
DEFS=$(DEFS) -DWITH_CURL -DWITH_REMOTE_RULES
51-
52-
# Enable PCRE2
53-
!IF "$(PCRE2)" != ""
54-
DEFS =$(DEFS) -DWITH_PCRE2
55-
!ENDIF
40+
41+
# Enables support for SecRemoteRules and external resources.
42+
DEFS=$(DEFS) -DWITH_CURL -DWITH_REMOTE_RULES
5643

5744
# Lua is optional
5845
!IF "$(LUA)" != ""
@@ -78,8 +65,8 @@ OBJS = mod_security2.obj apache2_config.obj apache2_io.obj apache2_util.obj \
7865
msc_parsers.obj msc_util.obj msc_pcre.obj persist_dbm.obj \
7966
msc_reqbody.obj msc_geo.obj msc_gsb.obj msc_crypt.obj msc_tree.obj msc_unicode.obj acmp.obj msc_lua.obj \
8067
msc_release.obj \
81-
msc_status_engine.obj \
82-
msc_remote_rules.obj \
68+
msc_status_engine.obj \
69+
msc_remote_rules.obj \
8370
msc_json.obj \
8471
libinjection/libinjection_html5.obj \
8572
libinjection/libinjection_sqli.obj \

0 commit comments

Comments
 (0)