Subject: Do not compile and link the bundled libpcre Author: Jose M Calhariz Index: bitkeeper-7.2.1-pcre/src/Makefile =================================================================== --- bitkeeper-7.2.1-pcre.orig/src/Makefile 2016-06-29 16:03:51.000000000 +0100 +++ bitkeeper-7.2.1-pcre/src/Makefile 2016-06-29 16:03:51.000000000 +0100 @@ -204,6 +204,7 @@ ifeq ($(shell uname -s), Darwin) endif XLIBS += -lz +XLIBS += -lpcre ifeq (clang, $(findstring clang, $(shell $(CC) --version))) WARNINGS += -Wno-unused-value -Wno-empty-body -Wno-self-assign @@ -300,7 +301,7 @@ SCRIPTS = applypatch bk.script import \ PSCR = t/doit t/guitest PROGS = libc/mtst$(EXE) LIBS = libc/libc.a tomcrypt/libtomcrypt.a tommath/libtommath.a -PCRELIB = gui/tcltk/pcre/local/lib/libpcre.a +PCRELIB = DATA = bkmsg.txt bkhelp.txt \ ../doc/bk_refcard.ps ../doc/bk_refcard.pdf ../RELEASE-NOTES \ dspec-changes dspec-changes-3.2 dspec-changes-4.0 dspec-changes-h \ @@ -308,11 +309,11 @@ DATA = bkmsg.txt bkhelp.txt \ dspec-changes-vv dspec-log dspec-prs CONTRIB = gui/ide/emacs/vc-bk.el contrib/git2bk.l -ALL = PCRE $(LIBS) $(BINS) $(SCRIPTS) $(PSCR) $(XTRA) \ +ALL = $(LIBS) $(BINS) $(SCRIPTS) $(PSCR) $(XTRA) \ $(PROGS) L-clean GUI L-doc $(DATA) CFLAGS = $(CC_DEBUG) -CPPFLAGS= -Ilibc -Itommath -Itomcrypt/src/headers -Igui/tcltk/pcre/local/include +CPPFLAGS= -Ilibc -Itommath -Itomcrypt/src/headers # Override this if you don't have it. RANLIB = ranlib @@ -557,7 +558,7 @@ import: import.sh port/$(SYS)_platform.s # Quick and dirty target so we can make all the gui tools without the rest .PHONY: GUI -GUI: PCRE $(BK) +GUI: $(BK) @$(MAKE) -Cgui Q=$(Q) BK=$(HERE)/bk$(EXE) gui gui-nowrap GUI-nowrap: @@ -714,7 +715,7 @@ depend: $(SRCS) libc/system.h: FORCE $(MAKE) -C libc system.h -sccs.h: PCRE +sccs.h: .PHONY: PCRE PCRE: $(MAKE) Q=$(Q) -Cgui/tcltk pcre Index: bitkeeper-7.2.1-pcre/src/gui/tcltk/Makefile =================================================================== --- bitkeeper-7.2.1-pcre.orig/src/gui/tcltk/Makefile 2016-06-29 16:37:52.789180098 +0100 +++ bitkeeper-7.2.1-pcre/src/gui/tcltk/Makefile 2016-06-29 16:42:23.203642094 +0100 @@ -105,7 +105,7 @@ LIBTCL=$(BKROOT)/src/gui/tcltk/tcl/$S/li endif LIBTOMCRYPT=$(BKROOT)/src/tomcrypt/libtomcrypt.a TOMMATH=$(BKROOT)/src/tommath -LIBPCRE=$(BKROOT)/src/gui/tcltk/pcre/local/lib/libpcre.a +LIBPCRE= all: version.sh $(if $(Q),@echo Building Tcl/Tk,) @@ -142,7 +142,7 @@ tcl/$S/Makefile: tcl/$S/configure $(LIBP $(if $(Q),@echo Configuring Tcl,) $(Q)cd tcl/$S; \ ./configure $(QUIET) \ - --disable-info-body --enable-pcre=default --with-pcre=../../pcre/local \ + --disable-info-body --enable-pcre=default \ $(ENABLE_64BIT) $(SHARED) $(SYMBOLS) \ --with-tommath=$(TOMMATH) @@ -311,7 +311,7 @@ bin/bkgui$(EXE): tk/$S/Makefile bin/tcls rm -rf bin/bkgui$(EXE) lib/tk* cd tk/$S && \ $(MAKE) prefix= exec_prefix= INSTALL_ROOT=../.. \ - XLIBS="$(LIBTOMCRYPT) $(LIBPCRE)" \ + XLIBS="$(LIBTOMCRYPT) -lpcre" \ BK_TCL_LIB="$(LIBTCL)" \ install-binaries install-libraries rm -rf include usr lib/tk*/images Index: bitkeeper-7.2.1-pcre/src/gui/tcltk/tcl/unix/Makefile.in =================================================================== --- bitkeeper-7.2.1-pcre.orig/src/gui/tcltk/tcl/unix/Makefile.in 2016-05-16 20:30:23.000000000 +0100 +++ bitkeeper-7.2.1-pcre/src/gui/tcltk/tcl/unix/Makefile.in 2016-06-29 17:03:20.605705005 +0100 @@ -244,7 +244,7 @@ BK_INCLUDES = @BK_INCLUDES@ @BK_HDRS@ @BK_SRCS@ ifdef BK_DIR -BK_LIBS = $(BK_DIR)/tomcrypt/libtomcrypt.a $(BK_DIR)/gui/tcltk/pcre/.libs/libpcre.a +BK_LIBS = $(BK_DIR)/tomcrypt/libtomcrypt.a TOMMATH_DIR = $(BK_DIR)/tommath endif # Must be absolute because of the cd dltest $(DLTEST_DIR)/configure below. Index: bitkeeper-7.2.1-pcre/src/gui/tcltk/tk/unix/Makefile.in =================================================================== --- bitkeeper-7.2.1-pcre.orig/src/gui/tcltk/tk/unix/Makefile.in 2016-05-16 20:30:24.000000000 +0100 +++ bitkeeper-7.2.1-pcre/src/gui/tcltk/tk/unix/Makefile.in 2016-06-29 17:02:26.908420971 +0100 @@ -263,7 +263,7 @@ TCL_STUB_FLAGS = @TCL_STUB_FLAGS@ # Libraries to use when linking. This definition is determined by the # configure script. LIBS = @LIBS@ $(X11_LIB_SWITCHES) @TCL_LIBS@ -WISH_LIBS = $(TCL_LIB_SPEC) @LIBS@ $(X11_LIB_SWITCHES) @TCL_LIBS@ ${BK_LIBS} @EXTRA_WISH_LIBS@ +WISH_LIBS = $(TCL_LIB_SPEC) @LIBS@ $(X11_LIB_SWITCHES) @TCL_LIBS@ -lpcre ${BK_LIBS} @EXTRA_WISH_LIBS@ # The symbols below provide support for dynamic loading and shared # libraries. See configure.in for a description of what the @@ -317,7 +317,7 @@ XLIB_DIR = $(TOP_DIR)/xlib BK_DIR = @BK_DIR@ @BK_LIBS@ ifdef BK_DIR -BK_LIBS = $(BK_DIR)/tomcrypt/libtomcrypt.a $(BK_DIR)/gui/tcltk/pcre/.libs/libpcre.a +BK_LIBS = $(BK_DIR)/tomcrypt/libtomcrypt.a endif #----------------------------------------------------------------