Page MenuHomeFreeBSD

Mk/bsd.xorg.mk: For USE_XORG=xft, added freetype2 to CFLAGS and CXXFLAGS.
AbandonedPublic

Authored by yuri on Dec 16 2017, 4:43 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mar 18 2024, 1:59 AM
Unknown Object (File)
Jan 28 2024, 9:21 PM
Unknown Object (File)
Dec 21 2023, 11:14 PM
Unknown Object (File)
Dec 20 2023, 8:12 AM
Unknown Object (File)
Nov 15 2023, 11:19 AM
Unknown Object (File)
Oct 18 2023, 7:14 PM
Unknown Object (File)
Sep 24 2023, 6:15 PM
Unknown Object (File)
Sep 21 2023, 5:33 PM
Subscribers

Details

Reviewers
tcberner
adamw
mat
Group Reviewers
O5: Ports Framework(Owns No Changed Paths)
portmgr
Summary

include/X11/Xft/Xft.h includes ft2build.h from freetype2, so freetype2 should always be in the flags.

Diff Detail

Repository
rP FreeBSD ports repository
Lint
No Lint Coverage
Unit
No Test Coverage
Build Status
Buildable 13613
Build 13836: arc lint + arc unit

Event Timeline

yuri retitled this revision from Mk/bsd.xorg.mk: For USE_XORG=xft added freetype2 to CFLAGS and CXXFLAGS. to Mk/bsd.xorg.mk: For USE_XORG=xft, added freetype2 to CFLAGS and CXXFLAGS..

It seems like you want to patch a broken configure script in the ports framework.

This path should already be set in the pkconfig file of the freetype port. If the depending software does not use that properly, that's the place you need to fix.

It seems like you want to patch a broken configure script in the ports framework.

This path should already be set in the pkconfig file of the freetype port. If the depending software does not use that properly, that's the place you need to fix.

What if they don't use pkg-config? If this is a static dependency, why not patch it in the framework? Why should everybody add freetype2 include?

It can lead to too much stuff in the include path. For example with Qt5, we needed to make sure that no -I/usr/local/incldue was present during compiling. Or the ports would use the installed headers instead of their new ones during upgrade.

So such a change has great destructive potential :)

So, to clarify this, USE_XORG=xft currently isn't sufficient to use Xft. All users need to also add the freetype2 include path. This doesn't appear to be normal that everybody should remember to also include something else. It makes much more sense if USE_XORG=xft took care of everything needed for Xft.

It can lead to too much stuff in the include path. For example with Qt5, we needed to make sure that no -I/usr/local/incldue was present during compiling. Or the ports would use the installed headers instead of their new ones during upgrade.

So such a change has great destructive potential :)

Ok, let's see what pkgmgr says about this. :) Or should I just delete it?

If the framework can't specify the needed include path, this is a problem in itself. Because logically this include should always come with USE_XORG=xft.

I don't think it's the framework's job to work around broken configure scripts.
Most ports using xft don't need this.

I don't think it's the framework's job to work around broken configure scripts.
Most ports using xft don't need this.

This is because many of them were patched for this: graphics/xfractint, games/seahaven.

In D13515#282533, @yuri wrote:

This is because many of them were patched for this: graphics/xfractint, games/seahaven.

Given the number of patches those 2 ports need, they are bad examples.

In D13515#282533, @yuri wrote:

This is because many of them were patched for this: graphics/xfractint, games/seahaven.

Given the number of patches those 2 ports need, they are bad examples.

If I wanted to write a project, needing Xft, from scratch, I would need to add USE_XORG=xft and CXXFLAGS+=-I${LOCALBASE}/include/freetype2.

The first part should suffice. Why do I *always* need the second part? This doesn't make any sense.

Most graphics ports already need freetype, or it seeps in through some dependencies, this is why they don't have to be patched.

In D13515#282538, @yuri wrote:
In D13515#282533, @yuri wrote:

This is because many of them were patched for this: graphics/xfractint, games/seahaven.

Given the number of patches those 2 ports need, they are bad examples.

If I wanted to write a project, needing Xft, from scratch, I would need to add USE_XORG=xft and CXXFLAGS+=-I${LOCALBASE}/include/freetype2.

The first part should suffice. Why do I *always* need the second part? This doesn't make any sense.

Most graphics ports already need freetype, or it seeps in through some dependencies, this is why they don't have to be patched.

If you use pkconfig it would work, and using some

In D13515#282538, @yuri wrote:
In D13515#282533, @yuri wrote:

This is because many of them were patched for this: graphics/xfractint, games/seahaven.

Given the number of patches those 2 ports need, they are bad examples.

If I wanted to write a project, needing Xft, from scratch, I would need to add USE_XORG=xft and CXXFLAGS+=-I${LOCALBASE}/include/freetype2.

The first part should suffice. Why do I *always* need the second part? This doesn't make any sense.

Most graphics ports already need freetype, or it seeps in through some dependencies, this is why they don't have to be patched.

Or you should rather use pkconfig to query those flags :)... If you need to do it by foot.

Closing this since it met an unexpected resistance.

In D13515#282592, @yuri wrote:

Closing this since it met an unexpected resistance.

This is a really rude thing to write.

In D13515#283271, @mat wrote:
In D13515#282592, @yuri wrote:

Closing this since it met an unexpected resistance.

This is a really rude thing to write.

In which language is this rude? In English it is not:

There is nothing rude in it. This is meant as a statement of fact or opinion, and nothing more.