mirror of
https://github.com/openbsd/xenocara.git
synced 2025-12-11 11:49:01 +00:00
build u_printf.cpp with -ffunction-sections -fdata-sections and
link libmesa_util.a users with --gc-sections avoids unwanted external references in shared libraries: _ZNKSt3__112basic_stringIcNS_11char_traitsIcEENS_9allocatorIcEEE4findEcm _ZNKSt3__121__basic_string_commonILb1EE20__throw_length_errorEv _ZdlPv _Znwm __gxx_personality_v0 follows what the meson build does problem reported by sthen@ when building sd2-ttf on i386
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.4 2021/08/01 01:52:49 jsg Exp $
|
||||
# $OpenBSD: Makefile,v 1.5 2022/02/25 06:23:08 jsg Exp $
|
||||
|
||||
.include <bsd.xconf.mk>
|
||||
|
||||
@@ -41,6 +41,7 @@ CPPFLAGS+= -I${MESA_SRC}/src/egl/main \
|
||||
LDADD+= -Wl,--as-needed -Wl,--allow-shlib-undefined -Wl,--start-group \
|
||||
${.CURDIR}/../libmesa_util/${__objdir}/libmesa_util.a \
|
||||
${.CURDIR}/../libmesa_format/${__objdir}/libmesa_format.a \
|
||||
-Wl,--gc-sections \
|
||||
-lz -lm \
|
||||
-L${X11BASE}/lib -lX11-xcb -lX11 -lxcb -lxcb-xfixes
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.3 2021/07/22 11:10:09 jsg Exp $
|
||||
# $OpenBSD: Makefile,v 1.4 2022/02/25 06:23:08 jsg Exp $
|
||||
|
||||
.include <bsd.xconf.mk>
|
||||
|
||||
@@ -72,7 +72,8 @@ LDADD+= -L${.CURDIR}/../libglapi/${__objdir} -lglapi \
|
||||
${.CURDIR}/../libglapi_static/${__objdir}/libglapi_static.a \
|
||||
${.CURDIR}/../libloader/${__objdir}/libloader.a \
|
||||
${.CURDIR}/../libxmlconfig/${__objdir}/libxmlconfig.a \
|
||||
${.CURDIR}/../libmesa_util/${__objdir}/libmesa_util.a
|
||||
${.CURDIR}/../libmesa_util/${__objdir}/libmesa_util.a \
|
||||
-Wl,--gc-sections
|
||||
|
||||
.if ${XENOCARA_BUILD_DRI3:L} == "yes"
|
||||
LDADD+= ${.CURDIR}/../libloader_dri3_helper/${__objdir}/libloader_dri3_helper.a
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.4 2022/02/24 02:29:48 jsg Exp $
|
||||
# $OpenBSD: Makefile,v 1.5 2022/02/25 06:23:08 jsg Exp $
|
||||
|
||||
.include <bsd.xconf.mk>
|
||||
|
||||
@@ -24,6 +24,7 @@ LDADD+= -Wl,--as-needed -Wl,--start-group \
|
||||
${.CURDIR}/../libmesa_util/${__objdir}/libmesa_util.a \
|
||||
${.CURDIR}/../libmesa_format/${__objdir}/libmesa_format.a \
|
||||
${.CURDIR}/../libxmlconfig/${__objdir}/libxmlconfig.a \
|
||||
-Wl,--gc-sections \
|
||||
-lz -lm -lexpat
|
||||
|
||||
.if ${XENOCARA_BUILD_DRI:L} == "yes"
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# $OpenBSD: Makefile,v 1.3 2022/02/24 02:29:49 jsg Exp $
|
||||
# $OpenBSD: Makefile,v 1.4 2022/02/25 06:23:08 jsg Exp $
|
||||
|
||||
LIB= mesa_util
|
||||
|
||||
@@ -65,7 +65,7 @@ SRCS+= format_srgb.c
|
||||
.include "../Makefile.inc"
|
||||
|
||||
CFLAGS+= ${C_VIS_ARGS}
|
||||
CXXFLAGS+= ${CXX_VIS_ARGS}
|
||||
CXXFLAGS+= ${CXX_VIS_ARGS} -ffunction-sections -fdata-sections
|
||||
CPPFLAGS+= -I${MESA_SRC}/src/util \
|
||||
-I${MESA_SRC}/src/mesa \
|
||||
-I${MESA_SRC}/src/gallium/include \
|
||||
|
||||
Reference in New Issue
Block a user