lib, programs: include common_defs.h by relative path

It's better to use a relative path, so that people not using the
Makefile don't have to put -Icommon on their compiler command line.
This commit is contained in:
Eric Biggers 2020-05-08 23:03:58 -07:00
parent 263d8ca7a9
commit 3dfd93e365
4 changed files with 4 additions and 4 deletions

View File

@ -45,7 +45,7 @@ cc-option = $(shell if $(CC) $(1) -c -x c /dev/null -o /dev/null \
1>&2 2>/dev/null; then echo $(1); fi) 1>&2 2>/dev/null; then echo $(1); fi)
override CFLAGS := \ override CFLAGS := \
-O2 -fomit-frame-pointer $(CFLAGS) -std=c99 -I. -Icommon \ -O2 -fomit-frame-pointer $(CFLAGS) -std=c99 -I. \
-Wall -Wundef \ -Wall -Wundef \
$(call cc-option,-Wpedantic) \ $(call cc-option,-Wpedantic) \
$(call cc-option,-Wdeclaration-after-statement) \ $(call cc-option,-Wdeclaration-after-statement) \

View File

@ -10,7 +10,7 @@
CC = cl CC = cl
LD = link LD = link
AR = lib AR = lib
CFLAGS = /MD /O2 -I. -Icommon CFLAGS = /MD /O2 -I.
LDFLAGS = LDFLAGS =
STATIC_LIB = libdeflatestatic.lib STATIC_LIB = libdeflatestatic.lib

View File

@ -12,7 +12,7 @@
#define BUILDING_LIBDEFLATE #define BUILDING_LIBDEFLATE
#include "common_defs.h" #include "../common/common_defs.h"
/* /*
* Prefix with "_libdeflate_" all global symbols which are not part of the API * Prefix with "_libdeflate_" all global symbols which are not part of the API

View File

@ -39,7 +39,7 @@
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include "common_defs.h" #include "../common/common_defs.h"
#ifdef __GNUC__ #ifdef __GNUC__
# define _printf(str_idx, args_idx) \ # define _printf(str_idx, args_idx) \