Always apply -DHAVE_UNISTD_H

This commit also moves the CPPFLAGS config from Makefile, which is
autogenerated, to build_handwritten.yaml, which is literally
handwritten.
pull/24979/head
Masaki Hara 4 years ago
parent 6d6c5ca009
commit d1589159c3
  1. 2
      Makefile
  2. 1
      build_handwritten.yaml

@ -2455,9 +2455,7 @@ PUBLIC_HEADERS_C += \
LIBZ_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(LIBZ_SRC)))) LIBZ_OBJS = $(addprefix $(OBJDIR)/$(CONFIG)/, $(addsuffix .o, $(basename $(LIBZ_SRC))))
$(LIBZ_OBJS): CFLAGS += -fvisibility=hidden $(LIBZ_OBJS): CFLAGS += -fvisibility=hidden
ifeq ($(SYSTEM),Darwin)
$(LIBZ_OBJS): CPPFLAGS += -DHAVE_UNISTD_H $(LIBZ_OBJS): CPPFLAGS += -DHAVE_UNISTD_H
endif
$(LIBDIR)/$(CONFIG)/libz.a: $(LIBZ_OBJS) $(LIBDIR)/$(CONFIG)/libz.a: $(LIBZ_OBJS)
$(E) "[AR] Creating $@" $(E) "[AR] Creating $@"

@ -216,6 +216,7 @@ defaults:
LDFLAGS: -g LDFLAGS: -g
zlib: zlib:
CFLAGS: -fvisibility=hidden CFLAGS: -fvisibility=hidden
CPPFLAGS: -DHAVE_UNISTD_H
php_config_m4: php_config_m4:
deps: deps:
- grpc - grpc

Loading…
Cancel
Save