You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
46 lines
1.7 KiB
46 lines
1.7 KiB
# --- SDE-COPYRIGHT-NOTE-BEGIN --- |
|
# This copyright note is auto-generated by ./scripts/Create-CopyPatch. |
|
# |
|
# Filename: package/.../haproxy/pcre-linking-fix.patch |
|
# Copyright (C) 2009 The OpenSDE Project |
|
# |
|
# More information can be found in the files COPYING and README. |
|
# |
|
# This patch file is dual-licensed. It is available under the license the |
|
# patched project is licensed under, as long as it is an OpenSource license |
|
# as defined at http://www.opensource.org/ (e.g. BSD, X11) or under the terms |
|
# of the GNU General Public License as published by the Free Software |
|
# Foundation; either version 2 of the License, or (at your option) any later |
|
# version. |
|
# --- SDE-COPYRIGHT-NOTE-END --- |
|
|
|
From: Christian Wiese <morfoh@opensde.org> |
|
Date: Thu, 20 Nov 2008 14:47:04 +0100 |
|
Subject: [PATCH] [BUILD] Fixed Makefile for linking pcre |
|
|
|
If both make parameters USE_PCRE and USE_STATIC_PCRE are set to 1 |
|
while building haproxy, pcre gets linked in dynamically. |
|
|
|
Therefore we check if USE_STATIC_PCRE was explicitely enabled to |
|
ommit the CFLAGS and LDFLAGS normally set if USE_PCRE is enabled. |
|
|
|
diff --git a/Makefile b/Makefile |
|
index f9696df..e141c5f 100644 |
|
--- a/Makefile |
|
+++ b/Makefile |
|
@@ -387,12 +387,14 @@ ifneq ($(USE_PCRE),) |
|
ifeq ($(PCREDIR),) |
|
PCREDIR := $(shell pcre-config --prefix 2>/dev/null || echo /usr/local) |
|
endif |
|
+ifneq ($(USE_STATIC_PCRE),1) |
|
OPTIONS_CFLAGS += -DUSE_PCRE -I$(PCREDIR)/include |
|
OPTIONS_LDFLAGS += -L$(PCREDIR)/lib -lpcreposix -lpcre |
|
+endif |
|
BUILD_OPTIONS += $(call ignore_implicit,USE_PCRE) |
|
endif |
|
|
|
-ifneq ($(USE_STATIC_PCRE),) |
|
+ifeq ($(USE_STATIC_PCRE),1) |
|
# PCREDIR is the directory hosting include/pcre.h and lib/libpcre.*. It is |
|
# automatically detected but can be forced if required. |
|
ifeq ($(PCREDIR),)
|
|
|