* [ptxdist] mediastreamer2: Bad search path when relinking library
@ 2018-02-02 10:59 Guillermo Rodriguez Garcia
2018-02-02 15:46 ` Michael Olbrich
0 siblings, 1 reply; 6+ messages in thread
From: Guillermo Rodriguez Garcia @ 2018-02-02 10:59 UTC (permalink / raw)
To: ptxdist
[-- Attachment #1.1: Type: text/plain, Size: 1184 bytes --]
Hi all,
I am trying to create a ptxdist package for mediastreamer2. By default,
releases come without a configure script, and with an autogen.sh that
requires intltoolize.
So I first tried the following:
In mediastreamer2.in:
select HOST_INTLTOOL
In mediasteamer2.make:
$(STATEDIR)/mediastreamer2.extract:
@$(call targetinfo)
@$(call clean, $(MEDIASTREAMER2_DIR))
@$(call extract, MEDIASTREAMER2)
cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
@$(call patchin, MEDIASTREAMER2)
@$(call touch)
However, this does not work because apparently ptxdist resolves
dependencies after the extract stage, so when autogen.sh is run, the
host-intltool package has not been installed yet.
So I tried to run autogen.sh from the extract.post stage instead:
$(STATEDIR)/mediastreamer2.extract.post:
@$(call targetinfo)
cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
@$(call touch)
This way, host-intltool is installed before autogen.sh is run, so that part
work. But this creates other problems: The install stage fails when trying
to relink some libraries.
What is the proper way to do this?
Thank you,
Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com
[-- Attachment #1.2: Type: text/html, Size: 2706 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ptxdist] mediastreamer2: Bad search path when relinking library
2018-02-02 10:59 [ptxdist] mediastreamer2: Bad search path when relinking library Guillermo Rodriguez Garcia
@ 2018-02-02 15:46 ` Michael Olbrich
2018-02-05 10:05 ` Guillermo Rodriguez Garcia
0 siblings, 1 reply; 6+ messages in thread
From: Michael Olbrich @ 2018-02-02 15:46 UTC (permalink / raw)
To: ptxdist
Hi,
On Fri, Feb 02, 2018 at 11:59:03AM +0100, Guillermo Rodriguez Garcia wrote:
> I am trying to create a ptxdist package for mediastreamer2. By default,
> releases come without a configure script, and with an autogen.sh that
> requires intltoolize.
>
> So I first tried the following:
>
> In mediastreamer2.in:
>
> select HOST_INTLTOOL
>
> In mediasteamer2.make:
>
> $(STATEDIR)/mediastreamer2.extract:
> @$(call targetinfo)
> @$(call clean, $(MEDIASTREAMER2_DIR))
> @$(call extract, MEDIASTREAMER2)
> cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> @$(call patchin, MEDIASTREAMER2)
> @$(call touch)
>
> However, this does not work because apparently ptxdist resolves
> dependencies after the extract stage, so when autogen.sh is run, the
> host-intltool package has not been installed yet.
>
> So I tried to run autogen.sh from the extract.post stage instead:
>
> $(STATEDIR)/mediastreamer2.extract.post:
> @$(call targetinfo)
> cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
I'm guessing you got that from the latest src-autoconf template. This is
still broken. It's missing the actual extract.post command:
@$(call world/patchin/post, @PACKAGE@)
> @$(call touch)
>
> This way, host-intltool is installed before autogen.sh is run, so that part
> work. But this creates other problems: The install stage fails when trying
> to relink some libraries.
>
> What is the proper way to do this?
The template whre you got this from is for packages where the source is
part of your BSP. I don't think this is the case for mediasteamer2. You
should use the 'target' new-package template.
For most packages the tarball contains the configure script. In that case
nothing special need to happen. If the configure script is missing, then
you need to create a autogen.sh link.
e.g. like the libyaml package in PTXdist does this with
patches/libyaml-0.1.7/autogen.sh.
Regards,
Michael
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ptxdist] mediastreamer2: Bad search path when relinking library
2018-02-02 15:46 ` Michael Olbrich
@ 2018-02-05 10:05 ` Guillermo Rodriguez Garcia
2018-02-05 10:25 ` Michael Olbrich
0 siblings, 1 reply; 6+ messages in thread
From: Guillermo Rodriguez Garcia @ 2018-02-05 10:05 UTC (permalink / raw)
To: ptxdist
[-- Attachment #1.1: Type: text/plain, Size: 2957 bytes --]
Hi,
2018-02-02 16:46 GMT+01:00 Michael Olbrich <m.olbrich@pengutronix.de>:
> Hi,
>
> On Fri, Feb 02, 2018 at 11:59:03AM +0100, Guillermo Rodriguez Garcia wrote:
> > I am trying to create a ptxdist package for mediastreamer2. By default,
> > releases come without a configure script, and with an autogen.sh that
> > requires intltoolize.
> >
> > So I first tried the following:
> >
> > In mediastreamer2.in:
> >
> > select HOST_INTLTOOL
> >
> > In mediasteamer2.make:
> >
> > $(STATEDIR)/mediastreamer2.extract:
> > @$(call targetinfo)
> > @$(call clean, $(MEDIASTREAMER2_DIR))
> > @$(call extract, MEDIASTREAMER2)
> > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> > @$(call patchin, MEDIASTREAMER2)
> > @$(call touch)
> >
> > However, this does not work because apparently ptxdist resolves
> > dependencies after the extract stage, so when autogen.sh is run, the
> > host-intltool package has not been installed yet.
> >
> > So I tried to run autogen.sh from the extract.post stage instead:
> >
> > $(STATEDIR)/mediastreamer2.extract.post:
> > @$(call targetinfo)
> > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
>
> I'm guessing you got that from the latest src-autoconf template. This is
> still broken. It's missing the actual extract.post command:
>
No, I actually made that up myself, based on the documentation. The manual
mentions [1] that extract.post is a good place to "generate a configure
script out of an autotoolized configure.ac file for example", so that's
what I tried. Also the manual does not document any default rule when
extract.post is omitted (whereas it does so for other stages). So I didn't
know that I had to call world/patchin/post from my custom extract.post rule.
[1]:
https://ptxdist.org/doc/ref_manual.html#extract-post-stage-default-rule
>
> @$(call world/patchin/post, @PACKAGE@)
>
> > @$(call touch)
> >
> > This way, host-intltool is installed before autogen.sh is run, so that
> part
> > work. But this creates other problems: The install stage fails when
> trying
> > to relink some libraries.
> >
> > What is the proper way to do this?
>
> The template whre you got this from is for packages where the source is
> part of your BSP. I don't think this is the case for mediasteamer2. You
> should use the 'target' new-package template.
>
> For most packages the tarball contains the configure script. In that case
> nothing special need to happen. If the configure script is missing, then
> you need to create a autogen.sh link.
> e.g. like the libyaml package in PTXdist does this with
> patches/libyaml-0.1.7/autogen.sh.
>
Actually the mediastreamer2 package comes with its own autogen.sh script.
That's why I am running
cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
Is that correct? I guess that if there's an autogen.sh script in the
package, that should normally be used in preference to the generic ptxdist
version. Right?
Thanks,
Guillermo
[-- Attachment #1.2: Type: text/html, Size: 4196 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ptxdist] mediastreamer2: Bad search path when relinking library
2018-02-05 10:05 ` Guillermo Rodriguez Garcia
@ 2018-02-05 10:25 ` Michael Olbrich
2018-02-05 10:49 ` Guillermo Rodriguez Garcia
0 siblings, 1 reply; 6+ messages in thread
From: Michael Olbrich @ 2018-02-05 10:25 UTC (permalink / raw)
To: ptxdist
On Mon, Feb 05, 2018 at 11:05:40AM +0100, Guillermo Rodriguez Garcia wrote:
> Hi,
>
> 2018-02-02 16:46 GMT+01:00 Michael Olbrich <m.olbrich@pengutronix.de>:
>
> > Hi,
> >
> > On Fri, Feb 02, 2018 at 11:59:03AM +0100, Guillermo Rodriguez Garcia wrote:
> > > I am trying to create a ptxdist package for mediastreamer2. By default,
> > > releases come without a configure script, and with an autogen.sh that
> > > requires intltoolize.
> > >
> > > So I first tried the following:
> > >
> > > In mediastreamer2.in:
> > >
> > > select HOST_INTLTOOL
> > >
> > > In mediasteamer2.make:
> > >
> > > $(STATEDIR)/mediastreamer2.extract:
> > > @$(call targetinfo)
> > > @$(call clean, $(MEDIASTREAMER2_DIR))
> > > @$(call extract, MEDIASTREAMER2)
> > > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> > > @$(call patchin, MEDIASTREAMER2)
> > > @$(call touch)
> > >
> > > However, this does not work because apparently ptxdist resolves
> > > dependencies after the extract stage, so when autogen.sh is run, the
> > > host-intltool package has not been installed yet.
> > >
> > > So I tried to run autogen.sh from the extract.post stage instead:
> > >
> > > $(STATEDIR)/mediastreamer2.extract.post:
> > > @$(call targetinfo)
> > > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> >
> > I'm guessing you got that from the latest src-autoconf template. This is
> > still broken. It's missing the actual extract.post command:
> >
>
> No, I actually made that up myself, based on the documentation. The manual
> mentions [1] that extract.post is a good place to "generate a configure
> script out of an autotoolized configure.ac file for example", so that's
> what I tried. Also the manual does not document any default rule when
> extract.post is omitted (whereas it does so for other stages). So I didn't
> know that I had to call world/patchin/post from my custom extract.post rule.
Ok. That needs to be fixed in the documentation.
> >
> > @$(call world/patchin/post, @PACKAGE@)
> >
> > > @$(call touch)
> > >
> > > This way, host-intltool is installed before autogen.sh is run, so that
> > part
> > > work. But this creates other problems: The install stage fails when
> > trying
> > > to relink some libraries.
> > >
> > > What is the proper way to do this?
> >
> > The template whre you got this from is for packages where the source is
> > part of your BSP. I don't think this is the case for mediasteamer2. You
> > should use the 'target' new-package template.
> >
> > For most packages the tarball contains the configure script. In that case
> > nothing special need to happen. If the configure script is missing, then
> > you need to create a autogen.sh link.
> > e.g. like the libyaml package in PTXdist does this with
> > patches/libyaml-0.1.7/autogen.sh.
> >
>
> Actually the mediastreamer2 package comes with its own autogen.sh script.
> That's why I am running
>
> cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
>
> Is that correct? I guess that if there's an autogen.sh script in the
> package, that should normally be used in preference to the generic ptxdist
> version. Right?
Not quite.
1. If the configure exists, then don't call any autogen.sh unless configure
was not generated properly.
2. unless you have the source in local_src/ provide
patches/<package>-<version>/autogen.sh
3. If the autogen.sh from ptxdist works, then use it. The local autogen.sh
scipts in the packages often do other random stuff, such as calling
'configure' and the one in ptxdist does the right thing in most cases.
4. If you need to use the package specific autogen.sh, the
patches/<package>-<version>/autogen.sh should look like this:
-------
#!/bin/sh
exec ./autogen,sh
-------
Regards,
Michael
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ptxdist] mediastreamer2: Bad search path when relinking library
2018-02-05 10:25 ` Michael Olbrich
@ 2018-02-05 10:49 ` Guillermo Rodriguez Garcia
2018-02-05 11:04 ` Michael Olbrich
0 siblings, 1 reply; 6+ messages in thread
From: Guillermo Rodriguez Garcia @ 2018-02-05 10:49 UTC (permalink / raw)
To: ptxdist
[-- Attachment #1.1: Type: text/plain, Size: 4691 bytes --]
2018-02-05 11:25 GMT+01:00 Michael Olbrich <m.olbrich@pengutronix.de>:
> On Mon, Feb 05, 2018 at 11:05:40AM +0100, Guillermo Rodriguez Garcia wrote:
> > Hi,
> >
> > 2018-02-02 16:46 GMT+01:00 Michael Olbrich <m.olbrich@pengutronix.de>:
> >
> > > Hi,
> > >
> > > On Fri, Feb 02, 2018 at 11:59:03AM +0100, Guillermo Rodriguez Garcia
> wrote:
> > > > I am trying to create a ptxdist package for mediastreamer2. By
> default,
> > > > releases come without a configure script, and with an autogen.sh that
> > > > requires intltoolize.
> > > >
> > > > So I first tried the following:
> > > >
> > > > In mediastreamer2.in:
> > > >
> > > > select HOST_INTLTOOL
> > > >
> > > > In mediasteamer2.make:
> > > >
> > > > $(STATEDIR)/mediastreamer2.extract:
> > > > @$(call targetinfo)
> > > > @$(call clean, $(MEDIASTREAMER2_DIR))
> > > > @$(call extract, MEDIASTREAMER2)
> > > > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> > > > @$(call patchin, MEDIASTREAMER2)
> > > > @$(call touch)
> > > >
> > > > However, this does not work because apparently ptxdist resolves
> > > > dependencies after the extract stage, so when autogen.sh is run, the
> > > > host-intltool package has not been installed yet.
> > > >
> > > > So I tried to run autogen.sh from the extract.post stage instead:
> > > >
> > > > $(STATEDIR)/mediastreamer2.extract.post:
> > > > @$(call targetinfo)
> > > > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> > >
> > > I'm guessing you got that from the latest src-autoconf template. This
> is
> > > still broken. It's missing the actual extract.post command:
> > >
> >
> > No, I actually made that up myself, based on the documentation. The
> manual
> > mentions [1] that extract.post is a good place to "generate a configure
> > script out of an autotoolized configure.ac file for example", so that's
> > what I tried. Also the manual does not document any default rule when
> > extract.post is omitted (whereas it does so for other stages). So I
> didn't
> > know that I had to call world/patchin/post from my custom extract.post
> rule.
>
> Ok. That needs to be fixed in the documentation.
>
> > >
> > > @$(call world/patchin/post, @PACKAGE@)
> > >
> > > > @$(call touch)
> > > >
> > > > This way, host-intltool is installed before autogen.sh is run, so
> that
> > > part
> > > > work. But this creates other problems: The install stage fails when
> > > trying
> > > > to relink some libraries.
> > > >
> > > > What is the proper way to do this?
> > >
> > > The template whre you got this from is for packages where the source is
> > > part of your BSP. I don't think this is the case for mediasteamer2. You
> > > should use the 'target' new-package template.
> > >
> > > For most packages the tarball contains the configure script. In that
> case
> > > nothing special need to happen. If the configure script is missing,
> then
> > > you need to create a autogen.sh link.
> > > e.g. like the libyaml package in PTXdist does this with
> > > patches/libyaml-0.1.7/autogen.sh.
> > >
> >
> > Actually the mediastreamer2 package comes with its own autogen.sh script.
> > That's why I am running
> >
> > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> >
> > Is that correct? I guess that if there's an autogen.sh script in the
> > package, that should normally be used in preference to the generic
> ptxdist
> > version. Right?
>
> Not quite.
> 1. If the configure exists, then don't call any autogen.sh unless configure
> was not generated properly.
>
OK. configure does not exist in this case.
> 2. unless you have the source in local_src/ provide
> patches/<package>-<version>/autogen.sh
>
3. If the autogen.sh from ptxdist works, then use it. The local autogen.sh
> scipts in the packages often do other random stuff, such as calling
> 'configure' and the one in ptxdist does the right thing in most cases.
>
Interesting. In my case the ptxversion does not work because intltoolize
needs to be run as well. But it is good to know this.
For packages where the ptxdist version works, shall I just copy the generic
autogen.sh over to patches/<package>-<version>
Bonus question. If there are no other patches, ptxdist complains in the
extract stage saying that the series file was not found (although this does
not prevent it from continuing to the extract.post stage). Is this ok?
4. If you need to use the package specific autogen.sh, the
> patches/<package>-<version>/autogen.sh should look like this:
> -------
> #!/bin/sh
> exec ./autogen,sh
> -------
>
OK, this is good to know as well. This way I don't need to mess with stage
rules.
Thanks,
Guillermo Rodriguez Garcia
guille.rodriguez@gmail.com
[-- Attachment #1.2: Type: text/html, Size: 6923 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [ptxdist] mediastreamer2: Bad search path when relinking library
2018-02-05 10:49 ` Guillermo Rodriguez Garcia
@ 2018-02-05 11:04 ` Michael Olbrich
0 siblings, 0 replies; 6+ messages in thread
From: Michael Olbrich @ 2018-02-05 11:04 UTC (permalink / raw)
To: ptxdist
On Mon, Feb 05, 2018 at 11:49:38AM +0100, Guillermo Rodriguez Garcia wrote:
> 2018-02-05 11:25 GMT+01:00 Michael Olbrich <m.olbrich@pengutronix.de>:
> > > Actually the mediastreamer2 package comes with its own autogen.sh script.
> > > That's why I am running
> > >
> > > cd $(MEDIASTREAMER2_DIR) && [ -f configure ] || sh autogen.sh
> > >
> > > Is that correct? I guess that if there's an autogen.sh script in the
> > > package, that should normally be used in preference to the generic
> > ptxdist
> > > version. Right?
> >
> > Not quite.
> > 1. If the configure exists, then don't call any autogen.sh unless configure
> > was not generated properly.
> >
>
> OK. configure does not exist in this case.
>
>
> > 2. unless you have the source in local_src/ provide
> > patches/<package>-<version>/autogen.sh
> >
> 3. If the autogen.sh from ptxdist works, then use it. The local autogen.sh
> > scipts in the packages often do other random stuff, such as calling
> > 'configure' and the one in ptxdist does the right thing in most cases.
> >
>
> Interesting. In my case the ptxversion does not work because intltoolize
> needs to be run as well. But it is good to know this.
ok.
> For packages where the ptxdist version works, shall I just copy the generic
> autogen.sh over to patches/<package>-<version>
Exactly.
> Bonus question. If there are no other patches, ptxdist complains in the
> extract stage saying that the series file was not found (although this does
> not prevent it from continuing to the extract.post stage). Is this ok?
Yes, that's ok. I think we fixed this in later version. I don't see this
warning with ptxdist master.
> 4. If you need to use the package specific autogen.sh, the
> > patches/<package>-<version>/autogen.sh should look like this:
> > -------
> > #!/bin/sh
> > exec ./autogen,sh
> > -------
> >
>
> OK, this is good to know as well. This way I don't need to mess with stage
> rules.
That's the reason why we implemented this. :-)
Michael
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2018-02-05 11:04 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-02 10:59 [ptxdist] mediastreamer2: Bad search path when relinking library Guillermo Rodriguez Garcia
2018-02-02 15:46 ` Michael Olbrich
2018-02-05 10:05 ` Guillermo Rodriguez Garcia
2018-02-05 10:25 ` Michael Olbrich
2018-02-05 10:49 ` Guillermo Rodriguez Garcia
2018-02-05 11:04 ` Michael Olbrich
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox