tech-pkg archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Making builtin fontconfig usable again on NetBSD (or, why libuuid bl3 is included in fontconfig bl3?)
Hello folks,
as analyzed by Thomas (<wiz>) last year in `Using fontconfig-2.13 from
xsrc on NetBSD [was Re: libuuid_ul and fontconfig]' thread on tech-pkg@:
<https://mail-index.NetBSD.org/tech-pkg/2019/06/19/msg021438.html>
builtin fontconfig could not be used in NetBSD because libuuid bl3 is
included unconditionally.
In NetBSD builtin fontconfig has an internal libuuid that has symbols
renamed (libuuid_ul) and so, at least on NetBSD, libuuid bl3 should not
be included (the attached patch basically just do that). I have tested
this patch on NetBSD-current and pkgsrc-current and I have not noticed
any regression. (Actually I think that also without this patch,
most/all(?) packages depending on fontconfig in pkgsrc are actually
linked against builtin fontconfig!)
Thomas, do you recall why libuuid bl3 was added to fontconfig
buildlink3? (cvs log does not seem to help)
If that libuuid bl3 inclusion is really needed on other platforms is it
okay to commit the proposed patch in this email?
If there won't be any negative feedbacks I would like to commit this
patch in 2 weeks.
Thank you!
fontconfig: Adjust buildlink3.mk to possibly use builtin one in NetBSD
In NetBSD, builtin fontconfig has an internal and with symbols
renamed libuuid (libuuid_ul). Avoid including it in that case.
Problem originally analyzed by <wiz> in:
<https://mail-index.NetBSD.org/tech-pkg/2019/06/19/msg021438.html>
XXX: As <mrg> pointed out in that thread probably uuid bl3 should not
XXX: be included there at all. `cvs annotate' and `cvs log' does not
XXX: contain any rationale in adding it.
Index: buildlink3.mk
===================================================================
RCS file: /cvsroot/pkgsrc/fonts/fontconfig/buildlink3.mk,v
retrieving revision 1.37
diff -u -p -r1.37 buildlink3.mk
--- buildlink3.mk 9 Sep 2019 12:22:03 -0000 1.37
+++ buildlink3.mk 10 Jul 2020 10:27:42 -0000
@@ -5,14 +5,24 @@ BUILDLINK_TREE+= fontconfig
.if !defined(FONTCONFIG_BUILDLINK3_MK)
FONTCONFIG_BUILDLINK3_MK:=
+.if !defined(USE_BUILTIN.fontconfig)
+CHECK_BUILTIN.fontconfig:= yes
+. include "../../fonts/fontconfig/builtin.mk"
+CHECK_BUILTIN.fontconfig:= no
+.endif
+
BUILDLINK_API_DEPENDS.fontconfig+= fontconfig>=2.11.91
BUILDLINK_ABI_DEPENDS.fontconfig+= fontconfig>=2.13.0
BUILDLINK_PKGSRCDIR.fontconfig?= ../../fonts/fontconfig
+. include "../../mk/bsd.fast.prefs.mk"
+
.include "../../archivers/bzip2/buildlink3.mk"
.include "../../devel/gettext-lib/buildlink3.mk"
.include "../../devel/zlib/buildlink3.mk"
+. if !empty(USE_BUILTIN.fontconfig:M[Yy][Ee]) && ${OPSYS} == "NetBSD"
.include "../../devel/libuuid/buildlink3.mk"
+. endif
.include "../../graphics/freetype2/buildlink3.mk"
.include "../../textproc/expat/buildlink3.mk"
.endif # FONTCONFIG_BUILDLINK3_MK
Index: builtin.mk
===================================================================
RCS file: /cvsroot/pkgsrc/fonts/fontconfig/builtin.mk,v
retrieving revision 1.13
diff -u -p -r1.13 builtin.mk
--- builtin.mk 2 Nov 2019 22:24:40 -0000 1.13
+++ builtin.mk 10 Jul 2020 10:27:42 -0000
@@ -43,6 +43,7 @@ MAKEVARS+= BUILTIN_PKG.fontconfig
### exists, and set USE_BUILTIN.<pkg> appropriate ("yes" or "no").
###
+USE_BUILTIN.fontconfig= yes
.if !defined(USE_BUILTIN.fontconfig)
. if ${PREFER.fontconfig} == "pkgsrc"
USE_BUILTIN.fontconfig= no
@@ -54,7 +55,7 @@ USE_BUILTIN.fontconfig= yes
. for _dep_ in ${BUILDLINK_API_DEPENDS.fontconfig}
. if !empty(USE_BUILTIN.fontconfig:M[yY][eE][sS])
USE_BUILTIN.fontconfig!= \
- if ${PKG_ADMIN} pmatch ${_dep_:Q} ${BUILTIN_PKG.fontconfig:Q}; then \
+ if ${PKG_ADMIN} pmatch ${_dep_:Q} ${BUILTIN_PKG.fontconfig}; then \
${ECHO} yes; \
else \
${ECHO} no; \
Home |
Main Index |
Thread Index |
Old Index