1
0
mirror of https://github.com/postgres/postgres.git synced 2025-08-25 20:23:07 +03:00

Split all OBJS style lines in makefiles into one-line-per-entry style.

When maintaining or merging patches, one of the most common sources
for conflicts are the list of objects in makefiles. Especially when
the split across lines has been changed on both sides, which is
somewhat common due to attempting to stay below 80 columns, those
conflicts are unnecessarily laborious to resolve.

By splitting, and alphabetically sorting, OBJS style lines into one
object per line, conflicts should be less frequent, and easier to
resolve when they still occur.

Author: Andres Freund
Discussion: https://postgr.es/m/20191029200901.vww4idgcxv74cwes@alap3.anarazel.de
This commit is contained in:
Andres Freund
2019-11-05 14:41:07 -08:00
parent 66c61c81b9
commit 01368e5d9d
147 changed files with 1271 additions and 302 deletions

View File

@@ -28,7 +28,9 @@ SHLIB_PREREQS = submake-ecpglib submake-pgtypeslib
SHLIB_EXPORTS = exports.txt
OBJS= informix.o $(WIN32RES)
OBJS = \
$(WIN32RES) \
informix.o
PKG_CONFIG_REQUIRES_PRIVATE = libecpg libpgtypes

View File

@@ -22,8 +22,18 @@ override CPPFLAGS := -I../include -I$(top_srcdir)/src/interfaces/ecpg/include \
-I$(libpq_srcdir) -I$(top_builddir)/src/port -DFRONTEND $(CPPFLAGS)
override CFLAGS += $(PTHREAD_CFLAGS)
OBJS= execute.o typename.o descriptor.o sqlda.o data.o error.o prepare.o \
memory.o connect.o misc.o $(WIN32RES)
OBJS = \
$(WIN32RES) \
connect.o \
data.o \
descriptor.o \
error.o \
execute.o \
memory.o \
misc.o \
prepare.o \
sqlda.o \
typename.o
SHLIB_LINK_INTERNAL = -L../pgtypeslib -lpgtypes $(libpq_pgport_shlib)
SHLIB_LINK = $(filter -lintl -lm, $(LIBS)) $(PTHREAD_LIBS)

View File

@@ -27,8 +27,14 @@ SHLIB_LINK += $(filter -lintl -lm, $(LIBS))
SHLIB_EXPORTS = exports.txt
OBJS= numeric.o datetime.o common.o dt_common.o timestamp.o interval.o \
$(WIN32RES)
OBJS = \
$(WIN32RES) \
common.o \
datetime.o \
dt_common.o \
interval.o \
numeric.o \
timestamp.o
all: all-lib

View File

@@ -23,9 +23,20 @@ override CPPFLAGS := -I../include -I$(top_srcdir)/src/interfaces/ecpg/include \
override CFLAGS += $(PTHREAD_CFLAGS)
OBJS= preproc.o pgc.o type.o ecpg.o output.o parser.o \
keywords.o c_keywords.o ecpg_keywords.o typename.o descriptor.o variable.o \
$(WIN32RES)
OBJS = \
$(WIN32RES) \
c_keywords.o \
descriptor.o \
ecpg.o \
ecpg_keywords.o \
keywords.o \
output.o \
parser.o \
pgc.o \
preproc.o \
type.o \
typename.o \
variable.o
# where to find gen_keywordlist.pl and subsidiary files
TOOLSDIR = $(top_srcdir)/src/tools

View File

@@ -27,19 +27,36 @@ endif
# The MSVC build system scrapes OBJS from this file. If you change any of
# the conditional additions of files to OBJS, update Mkvcbuild.pm to match.
OBJS= fe-auth.o fe-auth-scram.o fe-connect.o fe-exec.o fe-misc.o fe-print.o fe-lobj.o \
fe-protocol2.o fe-protocol3.o pqexpbuffer.o fe-secure.o \
legacy-pqsignal.o libpq-events.o
OBJS = \
fe-auth-scram.o \
fe-connect.o \
fe-exec.o \
fe-lobj.o \
fe-misc.o \
fe-print.o \
fe-protocol2.o \
fe-protocol3.o \
fe-secure.o \
legacy-pqsignal.o \
libpq-events.o \
pqexpbuffer.o \
fe-auth.o
# src/backend/utils/mb
OBJS += encnames.o wchar.o
OBJS += \
encnames.o \
wchar.o
ifeq ($(with_openssl),yes)
OBJS += fe-secure-openssl.o fe-secure-common.o
OBJS += \
fe-secure-common.o \
fe-secure-openssl.o
endif
ifeq ($(with_gssapi),yes)
OBJS += fe-gssapi-common.o fe-secure-gssapi.o
OBJS += \
fe-gssapi-common.o \
fe-secure-gssapi.o
endif
ifeq ($(PORTNAME), cygwin)
@@ -47,7 +64,9 @@ override shlib = cyg$(NAME)$(DLSUFFIX)
endif
ifeq ($(PORTNAME), win32)
OBJS += win32.o libpqrc.o
OBJS += \
libpqrc.o \
win32.o
libpqrc.o: libpq.rc
$(WINDRES) -i $< -o $@