We need to split up zlib headers in libretro-common to its own separate

dir
This commit is contained in:
twinaphex 2019-05-27 03:40:14 +02:00
parent 0f07206357
commit 22d762be67
28 changed files with 27 additions and 24 deletions

View File

@ -1594,7 +1594,7 @@ ifeq ($(HAVE_ZLIB), 1)
$(DEPS_DIR)/libz/trees.o \
$(DEPS_DIR)/libz/uncompr.o \
$(DEPS_DIR)/libz/zutil.o
INCLUDE_DIRS += -I$(LIBRETRO_COMM_DIR)/include/compat
INCLUDE_DIRS += -I$(LIBRETRO_COMM_DIR)/include/compat/zlib
DEFINES += -DWANT_ZLIB
else
LIBS += $(ZLIB_LIBS)

View File

@ -136,7 +136,8 @@ CFLAGS += -I. \
-Ideps/libz \
-Ideps/7zip \
-Ideps/stb \
-Ilibretro-common/include
-Ilibretro-common/include \
-Ilibretro-common/include/compat/zlib
CFLAGS += -DRARCH_INTERNAL -DRARCH_CONSOLE
CFLAGS += -DHAVE_FILTERS_BUILTIN $(DEFINES)

View File

@ -80,7 +80,7 @@ else
CFLAGS += -O2
endif
CFLAGS += -DHAVE_RPNG -Wall -I. -Ilibretro-common/include -std=gnu99 -s USE_ZLIB=1 \
CFLAGS += -DHAVE_RPNG -Wall -I. -Ilibretro-common/include -Ilibretro-common/include/compat/zlib -std=gnu99 -s USE_ZLIB=1 \
-s EXPORTED_FUNCTIONS="['_main', '_malloc', '_cmd_savefiles', '_cmd_save_state', '_cmd_take_screenshot']"
RARCH_OBJ := $(addprefix $(OBJDIR)/,$(OBJ))

View File

@ -838,6 +838,7 @@ endif
ifeq ($(HAVE_ZLIB), 1)
CFLAGS += -DHAVE_ZLIB
INCLUDE += -I./libretro-common/include/compat/zlib
endif
ifeq ($(WANT_ZLIB), 1)

View File

@ -112,7 +112,7 @@ APP_ICON := pkg/libnx/retroarch.jpg
ARCH := -march=armv8-a -mtune=cortex-a57 -mtp=soft -fPIE -mcpu=cortex-a57+crc+fp+simd
CFLAGS := -g -Wall -O3 -ffast-math -ffunction-sections \
$(ARCH) $(DEFINES) -Ideps -Ideps/libz -Ilibretro-common/include -Ideps/stb -I$(LIBNX)/include -I$(PORTLIBS)/include/ -include $(LIBNX)/include/switch.h #$(shell $(PORTLIBS)/bin/freetype-config --cflags)
$(ARCH) $(DEFINES) -Ideps -Ideps/libz -Ilibretro-common/include -Ilibretro-common/include/compat/zlib -Ideps/stb -I$(LIBNX)/include -I$(PORTLIBS)/include/ -include $(LIBNX)/include/switch.h #$(shell $(PORTLIBS)/bin/freetype-config --cflags)
CFLAGS += $(INCLUDE) -DSWITCH=1 -DHAVE_LIBNX=1 -DNXLINK=1 -DHAVE_SHADERPIPELINE -DHAVE_UPDATE_ASSETS -DHAVE_STB_FONT #-DHAVE_FREETYPE

View File

@ -83,7 +83,7 @@ STRIP := $(PREFIX)strip
NM := $(PREFIX)nm
LD := $(CXX)
INCDIRS := -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include -Ideps/stb
INCDIRS := -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include -Ideps/stb -Ilibretro-common/include/compat/zlib
LIBDIRS := -L.
ARCHFLAGS := -m64 -DORBIS

View File

@ -31,7 +31,7 @@ ifeq ($(MUTE_WARNINGS), 1)
endif
INCDIR = -I$(PS2DEV)/gsKit/include -I$(PS2SDK)/ports/include -I$(CDVD_DIR)/ee
INCDIR += -Ips2 -Ips2/include -Ilibretro-common/include
INCDIR += -Ips2 -Ips2/include -Ilibretro-common/include -Ilibretro-common/include/compat/zlib
INCDIR += -Ideps -Ideps/stb -Ideps/libz -Ideps/7zip -Ideps/pthreads -Ideps/pthreads/platform/ps2 -Ideps/pthreads/platform/helper
GPVAL = -G0
CFLAGS = $(OPTIMIZE_LV) $(DISABLE_WARNINGS) -ffast-math -fsingle-precision-constant

View File

@ -39,7 +39,8 @@ INCDIRS = -I. \
-Ideps/libz \
-Ideps/stb \
-Ideps/rcheevos/include \
-Ilibretro-common/include
-Ilibretro-common/include \
-Ilibretro-common/include/compat/zlib
# system platform
system_platform = unix

View File

@ -17,7 +17,7 @@ ELF_TARGET := retroarch_psl1ght.elf
EBOOT_PATH = pkg/ps3/USRDIR/EBOOT.BIN
CORE_PATH = pkg/ps3/USRDIR/cores/CORE.SELF
INCLUDE := -I. -I$(PS3DEV)/ppu/include -Ideps/libz -Ips3/gcmgl/include/export -Ips3/include -Ideps -Ideps/stb
INCLUDE := -I. -I$(PS3DEV)/ppu/include -Ideps/libz -Ips3/gcmgl/include/export -Ips3/include -Ideps -Ideps/stb -Ilibretro-common/include/compat/zlib
LIBDIRS := -L$(PS3DEV)/ppu/lib -L$(PS3DEV)/portlibs/ppu/lib -L.
MACHDEP := -D__CELLOS_LV2__ -D__PSL1GHT__

View File

@ -21,7 +21,7 @@ ifeq ($(WHOLE_ARCHIVE_LINK), 1)
WHOLE_END := -Wl,--no-whole-archive
endif
INCDIR = deps deps/stb deps/libz deps/7zip deps/pthreads deps/pthreads/platform/psp deps/pthreads/platform/helper libretro-common/include
INCDIR = deps deps/stb deps/libz deps/7zip deps/pthreads deps/pthreads/platform/psp deps/pthreads/platform/helper libretro-common/include libretro-common/include/compat/zlib
CFLAGS = $(OPTIMIZE_LV) -G0 -std=gnu99 -ffast-math -fsingle-precision-constant
ASFLAGS = $(CFLAGS)

View File

@ -46,7 +46,7 @@ endif
include $(LIBTRANSISTOR_HOME)/libtransistor.mk
INCDIRS := -I. -Ideps -Ideps/libz -Ilibretro-common/include -Ideps/stb -I$(LIBTRANSISTOR_HOME)/build/sdl2_install/include/SDL2/
INCDIRS := -I. -Ideps -Ideps/libz -Ilibretro-common/include -Ilibretro-common/include/compat/zlib -Ideps/stb -I$(LIBTRANSISTOR_HOME)/build/sdl2_install/include/SDL2/
LIBDIRS := -L.
TARGETS := $(TARGET).nro

View File

@ -83,7 +83,7 @@ STRIP := $(PREFIX)strip
NM := $(PREFIX)nm
LD := $(CXX)
INCDIRS := -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include -Ideps/stb
INCDIRS := -I. -Ideps/libz -Ideps/7zip -Ilibretro-common/include -Ilibretro-common/include/compat/zlib -Ideps/stb
LIBDIRS := -L.
ARCHFLAGS := -march=armv7-a -mfpu=neon -mfloat-abi=hard -DVITA

View File

@ -81,7 +81,7 @@ OS := Win32
OBJ :=
LIBS := -lm
DEFINES :=
DEFINES += -I. -Ilibretro-common/include -DRARCH_INTERNAL -DHAVE_OVERLAY
DEFINES += -I. -Ilibretro-common/include -Ilibretro-common/include/compat/zlib -DRARCH_INTERNAL -DHAVE_OVERLAY
#DEFINES += -DHAVE_VIDEO_LAYOUT
LDFLAGS := -L. -static-libgcc

2
deps/libz/adler32.c vendored
View File

@ -8,7 +8,7 @@
#define ZLIB_INTERNAL
#include <stdint.h>
#include <stddef.h>
#include <compat/zutil.h>
#include <zutil.h>
#define BASE 65521UL /* largest prime smaller than 65536 */
#define NMAX 5552

View File

@ -6,7 +6,7 @@
/* @(#) $Id$ */
#define ZLIB_INTERNAL
#include <compat/zlib.h>
#include <zlib.h>
/* ===========================================================================
Compresses the source buffer into the destination buffer. The level

2
deps/libz/deflate.h vendored
View File

@ -13,7 +13,7 @@
#ifndef DEFLATE_H
#define DEFLATE_H
#include <compat/zutil.h>
#include <zutil.h>
/* define NO_GZIP when compiling if you want to disable gzip header and
trailer creation by deflate(). NO_GZIP would be used to avoid linking in

2
deps/libz/gzguts.h vendored
View File

@ -22,7 +22,7 @@
#endif
#include <stdio.h>
#include <compat/zlib.h>
#include <zlib.h>
#ifdef STDC
# include <string.h>
# include <stdlib.h>

2
deps/libz/inffast.c vendored
View File

@ -3,7 +3,7 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/
#include <compat/zutil.h>
#include <zutil.h>
#include "inftrees.h"
#include "inflate.h"
#include "inffast.h"

2
deps/libz/inflate.c vendored
View File

@ -80,7 +80,7 @@
* The history for versions after 1.2.0 are in ChangeLog in zlib distribution.
*/
#include <compat/zutil.h>
#include <zutil.h>
#include "inftrees.h"
#include "inflate.h"
#include "inffast.h"

View File

@ -3,7 +3,7 @@
* For conditions of distribution and use, see copyright notice in zlib.h
*/
#include <compat/zutil.h>
#include <zutil.h>
#include "inftrees.h"
#define MAXBITS 15

2
deps/libz/uncompr.c vendored
View File

@ -6,7 +6,7 @@
/* @(#) $Id$ */
#define ZLIB_INTERNAL
#include <compat/zlib.h>
#include <zlib.h>
/* ===========================================================================
Decompresses the source buffer into the destination buffer. sourceLen is

2
deps/libz/zutil.c vendored
View File

@ -5,7 +5,7 @@
/* @(#) $Id$ */
#include <compat/zutil.h>
#include <zutil.h>
#ifndef Z_SOLO
# include "gzguts.h"
#endif

View File

@ -31,7 +31,7 @@
#include <encodings/crc32.h>
/* Only for MAX_WBITS */
#include <compat/zlib.h>
#include <zlib.h>
#ifndef CENTRAL_FILE_HEADER_SIGNATURE
#define CENTRAL_FILE_HEADER_SIGNATURE 0x02014b50

View File

@ -24,7 +24,7 @@
# define ZLIB_INTERNAL
#endif
#include <compat/zlib.h>
#include <zlib.h>
#if defined(STDC) && !defined(Z_SOLO)
# if !(defined(_WIN32_WCE) && defined(_MSC_VER))

View File

@ -23,7 +23,7 @@
#include <stdlib.h>
#include <string.h>
#include <compat/zlib.h>
#include <zlib.h>
#include <string/stdstring.h>
#include <streams/trans_stream.h>