From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Received: from mail-wm0-x22c.google.com ([2a00:1450:400c:c09::22c]) by metis.ext.pengutronix.de with esmtps (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from ) id 1buFOd-0005e4-At for ptxdist@pengutronix.de; Wed, 12 Oct 2016 11:00:19 +0200 Received: by mail-wm0-x22c.google.com with SMTP id b201so18843610wmb.0 for ; Wed, 12 Oct 2016 02:00:19 -0700 (PDT) MIME-Version: 1.0 In-Reply-To: <20161011144324.ebnloamidx4rhvps@pengutronix.de> References: <20161011144324.ebnloamidx4rhvps@pengutronix.de> From: Guillermo Rodriguez Garcia Date: Wed, 12 Oct 2016 11:00:12 +0200 Message-ID: Subject: Re: [ptxdist] Circular dependencies in ptxdist List-Id: PTXdist Development Mailing List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: ptxdist@pengutronix.de Content-Type: multipart/mixed; boundary="===============1824242382==" Errors-To: ptxdist-bounces@pengutronix.de Sender: "ptxdist" To: "ptxdist@pengutronix.de" --===============1824242382== Content-Type: multipart/alternative; boundary=047d7b3a8c8896c1fd053ea7383c --047d7b3a8c8896c1fd053ea7383c Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi Michael, El martes, 11 de octubre de 2016, Michael Olbrich escribi=C3=B3: > Hi, > > On Tue, Oct 11, 2016 at 09:26:02AM +0200, Guillermo Rodriguez Garcia wrot= e: > > I am trying to create a ptxdist package for Harfbuzz > > (https://www.freedesktop.org/wiki/Software/HarfBuzz/) but I have found > > that Harfbuzz has a circular dependency with freetype: FreeType can > > use Harfbuzz to improve hinting, but Hardbuzz needs FreeType to build. > > > > Typical advice on how to handle this is: First build freetype without > > Harfbuzz support, then build and install Harfbuzz, then rebuild and > > reinstall Freetype with Harfbuzz support. > > > > "Install FreeType, then HarfBuzz, then after HarfBuzz is installed, > > rebuild and reinstall FreeType". > > > > My question is, how can this handled in ptxdist? > > > > I am considering something like the following: > > > > 1. A Freetype_bootstrap package that will build FT without Harfbuzz, > > with an empty targetinstall stage. This is just so that Harfbuzz can > > build > > 2. A Harfbuzz package that requires Freetype_bootstrap, and does the > > actual targetinstall for Harfbuzz > > 3. Modify the Freetype package to add a "ENABLE_HARFBUZZ" option. If > > this is enabled, then Freetype also SELECTS Harfbuzz. > > > > Does this sound reasonable? > > > > Are there other cases like this in ptxdist ? > > I don't think there is a better solution. So just do it like this. I am just thinking that this does not completely solve the problem. If someone selects harfbuzz but not freetype, harfbuzz will build correctly but will fail at runtime because freetype will not be present. The obvious solution of making harfbuzz depend on freetype will not allow to build freetype --with-harfbuzz (chicken and egg problem) I am not sure how to solve this. Any ideas? Guillermo --=20 Guillermo Rodriguez Garcia guille.rodriguez@gmail.com --047d7b3a8c8896c1fd053ea7383c Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi Michael,

El martes, 11 de octubre de 2016, Michael Olbrich <m.olbrich@pengutronix.de> = escribi=C3=B3:
Hi,

On Tue, Oct 11, 2016 at 09:26:02AM +0200, Guillermo Rodriguez Garcia wrote:=
> I am trying to create a ptxdist package for Harfbuzz
> (https://www.freedesktop.org/wiki/Software/HarfBuzz/) = but I have found
> that Harfbuzz has a circular dependency with freetype: FreeType can > use Harfbuzz to improve hinting, but Hardbuzz needs FreeType to build.=
>
> Typical advice on how to handle this is: First build freetype without<= br> > Harfbuzz support, then build and install Harfbuzz, then rebuild and > reinstall Freetype with Harfbuzz support.
>
> "Install FreeType, then HarfBuzz, then after HarfBuzz is installe= d,
> rebuild and reinstall FreeType".
>
> My question is, how can this handled in ptxdist?
>
> I am considering something like the following:
>
> 1. A Freetype_bootstrap package that will build FT without Harfbuzz, > with an empty targetinstall stage. This is just so that Harfbuzz can > build
> 2. A Harfbuzz package that requires Freetype_bootstrap, and does the > actual targetinstall for Harfbuzz
> 3. Modify the Freetype package to add a "ENABLE_HARFBUZZ" op= tion. If
> this is enabled, then Freetype also SELECTS Harfbuzz.
>
> Does this sound reasonable?
>
> Are there other cases like this in ptxdist ?

I don't think there is a better solution. So just do it like this.

I am just thinking that this does not completel= y solve the problem. If someone selects harfbuzz but not freetype, harfbuzz= will build correctly but will fail at runtime because freetype will not be= present. The obvious solution of making harfbuzz depend on freetype will n= ot allow to build freetype --with-harfbuzz (chicken and egg problem)
<= div>
I am not sure how to solve this. Any ideas?
Guillermo=C2=A0




--
Guiller= mo Rodriguez Garcia
guille= .rodriguez@gmail.com
--047d7b3a8c8896c1fd053ea7383c-- --===============1824242382== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX18KcHR4ZGlzdCBt YWlsaW5nIGxpc3QKcHR4ZGlzdEBwZW5ndXRyb25peC5kZQ== --===============1824242382==--