1# 2# FreeType 2 GZip support configuration rules 3# 4 5 6# Copyright (C) 2002-2023 by 7# David Turner, Robert Wilhelm, and Werner Lemberg. 8# 9# This file is part of the FreeType project, and may only be used, modified, 10# and distributed under the terms of the FreeType project license, 11# LICENSE.TXT. By continuing to use, modify, or distribute this file you 12# indicate that you have read the license and understand and accept it 13# fully. 14 15 16# gzip driver directory 17# 18GZIP_DIR := $(SRC_DIR)/gzip 19 20 21# compilation flags for the driver 22# 23ifeq ($(SYSTEM_ZLIB),) 24 GZIP_COMPILE := $(CC) $(ANSIFLAGS) \ 25 $I$(subst /,$(COMPILER_SEP),$(GZIP_DIR)) \ 26 $(INCLUDE_FLAGS) \ 27 $(FT_CFLAGS) 28else 29 GZIP_COMPILE := $(CC) $(ANSIFLAGS) \ 30 $(INCLUDE_FLAGS) \ 31 $(FT_CFLAGS) 32endif 33 34 35# gzip support sources 36# 37# All source and header files get loaded by `ftgzip.c' only if SYSTEM_ZLIB 38# is not defined (regardless whether we have a `single' or a `multi' build). 39# 40ifeq ($(SYSTEM_ZLIB),) 41 GZIP_DRV_SRCS := $(GZIP_DIR)/adler32.c \ 42 $(GZIP_DIR)/crc32.c \ 43 $(GZIP_DIR)/crc32.h \ 44 $(GZIP_DIR)/ftzconf.h \ 45 $(GZIP_DIR)/inffast.c \ 46 $(GZIP_DIR)/inffast.h \ 47 $(GZIP_DIR)/inffixed.h \ 48 $(GZIP_DIR)/inflate.c \ 49 $(GZIP_DIR)/inflate.h \ 50 $(GZIP_DIR)/inftrees.c \ 51 $(GZIP_DIR)/inftrees.h \ 52 $(GZIP_DIR)/zlib.h \ 53 $(GZIP_DIR)/zutil.c \ 54 $(GZIP_DIR)/zutil.h 55endif 56 57# gzip driver object(s) 58# 59# GZIP_DRV_OBJ is used during both `single' and `multi' builds 60# 61GZIP_DRV_OBJ := $(OBJ_DIR)/ftgzip.$O 62 63 64# gzip main source file 65# 66GZIP_DRV_SRC := $(GZIP_DIR)/ftgzip.c 67 68 69# gzip support - object 70# 71$(GZIP_DRV_OBJ): $(GZIP_DRV_SRC) $(GZIP_DRV_SRCS) $(FREETYPE_H) 72 $(GZIP_COMPILE) $T$(subst /,$(COMPILER_SEP),$@ $(GZIP_DRV_SRC)) 73 74 75# update main driver object lists 76# 77DRV_OBJS_S += $(GZIP_DRV_OBJ) 78DRV_OBJS_M += $(GZIP_DRV_OBJ) 79 80 81# EOF 82