Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 1 | From 08a464e2b6bd31bb2bf4e258ebfa9b9d65805abf Mon Sep 17 00:00:00 2001 |
| 2 | From: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> |
| 3 | Date: Fri, 27 Nov 2015 15:17:02 +0100 |
| 4 | Subject: [PATCH] Fix build of shared library on architectures needing -fPIC |
| 5 | |
| 6 | Certain architectures, like Sparc and Sparc64 require objects to be |
| 7 | built with -fPIC (and not just -fpic) to be usable in shared |
| 8 | libraries. On other architectures, -fPIC is the same as -fpic so this |
| 9 | patch doesn't affect such architectures. |
| 10 | |
| 11 | Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons.com> |
| 12 | --- |
Patrick Williams | 520786c | 2023-06-25 16:20:36 -0500 | [diff] [blame] | 13 | Upstream-Status: Pending |
| 14 | |
Brad Bishop | 1a4b7ee | 2018-12-16 17:11:34 -0800 | [diff] [blame] | 15 | src/Makefile | 2 +- |
| 16 | 1 file changed, 1 insertion(+), 1 deletion(-) |
| 17 | |
| 18 | diff --git a/src/Makefile b/src/Makefile |
| 19 | index 95fe549..c293611 100755 |
| 20 | --- a/src/Makefile |
| 21 | +++ b/src/Makefile |
| 22 | @@ -110,7 +110,7 @@ $(BIN2_NAME): $(OBJS3) $(LIB_NAME) |
| 23 | |
| 24 | |
| 25 | x_%.o: %.cpp |
| 26 | - $(CXX) $(CXXFLAGS) $(USE_AUDIO) -D PATH_ESPEAK_DATA=\"$(DATADIR)\" -Wall -fpic -fvisibility=hidden -pedantic \ |
| 27 | + $(CXX) $(CXXFLAGS) $(USE_AUDIO) -D PATH_ESPEAK_DATA=\"$(DATADIR)\" -Wall -fPIC -fvisibility=hidden -pedantic \ |
| 28 | -I. -D LIBRARY -c -fno-exceptions $< -o x_$*.o |
| 29 | |
| 30 | $(LIB_NAME): $(OBJS2) |
| 31 | -- |
| 32 | 2.6.3 |
| 33 | |