Opened 10 years ago

Closed 10 years ago

Last modified 10 years ago

#584 closed defect (invalid)

nginx 1.6.0 failed to build (src/core/ngx_crypt.c: error: 'MD5_Update' is deprecated: first deprecated in OS X 10.7 [-Werror,-Wdeprecated-declarations])

Reported by: Siu Ching Pong (Asuka Kenji) Owned by:
Priority: blocker Milestone:
Component: nginx-core Version: 1.6.x
Keywords: Cc:
uname -a: Darwin localhost 13.2.0 Darwin Kernel Version 13.2.0: Thu Apr 17 23:03:13 PDT 2014; root:xnu-2422.100.13~1/RELEASE_X86_64 x86_64 i386 iMac13,2 Darwin
nginx -V: (Not available since there is compilation error)

Description

nginx:
1.6.0 (http://nginx.org/download/nginx-1.6.0.tar.gz)

OS:
Mac OS X 10.9.3

Compiler:

$ pkgutil --pkg-info=com.apple.pkg.CLTools_Executables
package-id: com.apple.pkg.CLTools_Executables
version: 5.1.0.0.1.1396320587
volume: /
location: /
install-time: 1401159658
groups: com.apple.FindSystemFiles.pkg-group com.apple.DevToolsBoth.pkg-group com.apple.DevToolsNonRelocatableShared.pkg-group

Steps to reproduce:

$ ./configure \
	--prefix=$HOME/WebHosting/root \
	--with-http_ssl_module \
	--with-pcre=$HOME/WebHosting/nginx-src/pcre-8.35 \
	--with-zlib=$HOME/WebHosting/nginx-src/zlib-1.2.8
$ make >make.log 2>&1

Workaround:
Remove the -Werror or the -Wdeprecated-declarations options from the compilation flags

Attachments (2)

make.log (28.7 KB ) - added by Siu Ching Pong (Asuka Kenji) 10 years ago.
The output from running "make"
make.2.log (180.9 KB ) - added by Siu Ching Pong (Asuka Kenji) 10 years ago.
The output from running "make" after removing "-Werror" from "Makefile"

Download all attachments as: .zip

Change History (5)

by Siu Ching Pong (Asuka Kenji), 10 years ago

Attachment: make.log added

The output from running "make"

comment:1 by Siu Ching Pong (Asuka Kenji), 10 years ago

There is no such a problem when compiling nginx 1.7.2.

comment:2 by Siu Ching Pong (Asuka Kenji), 10 years ago

Workaround:
After ./configure, edit objs/Makefile. The original line 3 looks like this:

CFLAGS =  -pipe  -O -Wall -Wextra -Wpointer-arith -Wconditional-uninitialized -Wno-unused-parameter -Werror -g 

Removing the -Werror makes it compile successfully:

CFLAGS =  -pipe  -O -Wall -Wextra -Wpointer-arith -Wconditional-uninitialized -Wno-unused-parameter -g 

The complete log is attached as make.2.log. There are other deprecation warnings.

Last edited 10 years ago by Siu Ching Pong (Asuka Kenji) (previous) (diff)

by Siu Ching Pong (Asuka Kenji), 10 years ago

Attachment: make.2.log added

The output from running "make" after removing "-Werror" from "Makefile"

comment:3 by Maxim Dounin, 10 years ago

Resolution: invalid
Status: newclosed

This is a bug in Apple's availability macros. Workaround was already committed, see 80bd391c90d1, and is available in nginx 1.7.2.

To build older versions with OS X system OpenSSL library, consider using the --with-cc-opt="-Wno-deprecated-declarations" configure option. Alternatively, install unmodified OpenSSL library, e.g., using MacPorts.

Note: See TracTickets for help on using tickets.