* cygport install infinite loop in src_postinstall under __prep_libtool_modules
@ 2020-07-04 19:35 Brian Inglis
2020-07-04 20:06 ` Marco Atzeri
2020-07-05 5:27 ` ASSI
0 siblings, 2 replies; 4+ messages in thread
From: Brian Inglis @ 2020-07-04 19:35 UTC (permalink / raw)
To: cygwin-apps
[-- Attachment #1: Type: text/plain, Size: 1310 bytes --]
See attached cygport --debug ...cygport install log.
Running cygport ... install, src_postinstall under __prep_libtool_modules after
"Fixing libtool modules:" does not find dll in:
$ find wget2-1.99.2-1.x86_64/ -name 'cygwget*'
wget2-1.99.2-1.x86_64/build/libwget/.libs/cygwget-0.dll
wget2-1.99.2-1.x86_64/inst/usr/bin/cygwget-0.dll
so it loops on /usr/share/cygport/lib/src_postinst.cygpart:1297ff:
while [ $(readlink -f ${ltlibdir}/${dlname%/bin/*}) != ${D}$(__host_prefix) ]
do
dlname=../${dlname}
done
until readlink returns root and just keeps on going, possibly because my Cygwin
home is a symlink to my Windows home, but this approach would have problems with
any symlinks along the path to the cygport dir, as $D is not similarly resolved.
I can wrap the other path in the condition in $(readlink -f ...) and it works
normally but this may not be the best approach here.
Alternatives, suggestions?
In this pre-package there is a check/test program and a DLL - is there another
package I could use as a template for how to split this into two packages?
--
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada
This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in IEC units and prefixes, physical quantities in SI.]
[-- Attachment #2: cygport-install-src_postinstall-prep_libtool_modules-loop.log --]
[-- Type: text/plain, Size: 9528 bytes --]
...
...
...
+ __prep_libtool_modules
+ local ltlibs ltlibdir ltlibname ltversion
+ local dlname origdlname library_names old_library inherited_linker_flags dependency_libs weak_library_names current age revision installed shouldnotlink dlopen dlpreopen libdir rep_requires
+ local keep=none
+ pushd /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst
+ builtin pushd /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst
++ find usr -name '*.la'
+ ltlibs=usr/lib/libwget.la
+ defined ltlibs
+ (( 1 != 1 ))
+ '[' -n usr/lib/libwget.la ']'
+ return 0
+ echo 'Fixing libtool modules:'
Fixing libtool modules:
++ grep '^# libtool (GNU' /usr/bin/libtool
++ cut -d ' ' -f 2-
+ ltversion='libtool (GNU libtool) 2.4.6'
+ for lib_la in ${ltlibs}
+ grep -q 'libtool library file' usr/lib/libwget.la
+ source usr/lib/libwget.la
++ dlname=../bin/cygwget-0.dll
++ library_names=libwget.dll.a
++ old_library=
++ inherited_linker_flags=
++ dependency_libs=' -liconv -lintl -lpthread -lpcre2-8 -lidn2 -lzstd -lbrotlidec -llzma -lz -lgpgme -lbz2 -lnghttp2 -lpsl -lnettle'
++ weak_library_names=
++ current=0
++ age=0
++ revision=0
++ installed=yes
++ shouldnotlink=no
++ dlopen=
++ dlpreopen=
++ libdir=/usr/lib
+ ltlibdir=usr/lib
+ for l in dlname library_names old_library
+ defined dlname
+ (( 1 != 1 ))
+ '[' -n ../bin/cygwget-0.dll ']'
+ return 0
+ for il in ${!l}
+ '[' '!' -f usr/lib/../bin/cygwget-0.dll ']'
+ for l in dlname library_names old_library
+ defined library_names
+ (( 1 != 1 ))
+ '[' -n libwget.dll.a ']'
+ return 0
+ for il in ${!l}
+ '[' '!' -f usr/lib/libwget.dll.a ']'
+ for l in dlname library_names old_library
+ defined old_library
+ (( 1 != 1 ))
+ '[' -n '' ']'
+ return 1
+ '[' xno '!=' xyes ']'
+ '[' x../bin/cygwget-0.dll = x ']'
+ case ${CTARGET} in
+ '[' -f usr/lib/libwget.dll.a ']'
+ chmod 0644 usr/lib/libwget.dll.a
+ test x86_64-pc-cygwin '!=' x86_64-pc-cygwin
+ origdlname=../bin/cygwget-0.dll
++ readlink -f usr/lib/..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../bin/cygwget-0.dll
++ readlink -f usr/lib/../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user/src/cygwin/wget2/wget2-1.99.2-1.x86_64 '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user/src/cygwin/wget2 '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user/src/cygwin '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user/src '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users/$user '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c/Users '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive/c '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc/cygdrive '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' /proc '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' / '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
++ prefix=/usr
++ echo -n /usr
+ '[' / '!=' /home/$USER/src/cygwin/wget2/wget2-1.99.2-1.x86_64/inst/usr ']'
+ dlname=../../../../../../../../../../../../../../bin/cygwget-0.dll
++ readlink -f usr/lib/../../../../../../../../../../../../../..
++ __host_prefix
++ local prefix
++ __host_is_embedded
++ local ret=1
++ case ${CHOST} in
++ return 1
++ [[ x86_64-pc-cygwin =~ -mingw32 ]]
++ inherited cross
++ local class
++ local classname
++ for class in "$@"
++ classname=cross
++ defined _cross_CYGCLASS_
++ (( 1 != 1 ))
++ '[' -n '' ']'
++ return 1
++ return 1
...
...
...
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cygport install infinite loop in src_postinstall under __prep_libtool_modules
2020-07-04 19:35 cygport install infinite loop in src_postinstall under __prep_libtool_modules Brian Inglis
@ 2020-07-04 20:06 ` Marco Atzeri
2020-07-05 19:29 ` Brian Inglis
2020-07-05 5:27 ` ASSI
1 sibling, 1 reply; 4+ messages in thread
From: Marco Atzeri @ 2020-07-04 20:06 UTC (permalink / raw)
To: cygwin-apps
On 04.07.2020 21:35, Brian Inglis wrote:
> See attached cygport --debug ...cygport install log.
>
> Running cygport ... install, src_postinstall under __prep_libtool_modules after
> "Fixing libtool modules:" does not find dll in:
>
> $ find wget2-1.99.2-1.x86_64/ -name 'cygwget*'
> wget2-1.99.2-1.x86_64/build/libwget/.libs/cygwget-0.dll
> wget2-1.99.2-1.x86_64/inst/usr/bin/cygwget-0.dll
>
> so it loops on /usr/share/cygport/lib/src_postinst.cygpart:1297ff:
>
> while [ $(readlink -f ${ltlibdir}/${dlname%/bin/*}) != ${D}$(__host_prefix) ]
> do
> dlname=../${dlname}
> done
>
> until readlink returns root and just keeps on going, possibly because my Cygwin
> home is a symlink to my Windows home, but this approach would have problems with
> any symlinks along the path to the cygport dir, as $D is not similarly resolved.
>
> I can wrap the other path in the condition in $(readlink -f ...) and it works
> normally but this may not be the best approach here.
> Alternatives, suggestions?
>
> In this pre-package there is a check/test program and a DLL - is there another
> package I could use as a template for how to split this into two packages?
>
I assume you are building under some link structure.
I was hit by long time by it as I was using
/pub -> /cygdrive/d/cyg_pub
and building in it.
Two options:
1) patch cygport
I proposed something for that case
https://sourceware.org/pipermail/cygwin-apps/2020-April/039990.html
2) mount the directory instead of using links.
I put this in my fstab and removed the link
d:\cyg_pub /pub NTFS binary,posix=1,nouser 0 0
Regards
Marco
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cygport install infinite loop in src_postinstall under __prep_libtool_modules
2020-07-04 19:35 cygport install infinite loop in src_postinstall under __prep_libtool_modules Brian Inglis
2020-07-04 20:06 ` Marco Atzeri
@ 2020-07-05 5:27 ` ASSI
1 sibling, 0 replies; 4+ messages in thread
From: ASSI @ 2020-07-05 5:27 UTC (permalink / raw)
To: cygwin-apps
Brian Inglis writes:
> until readlink returns root and just keeps on going, possibly because my Cygwin
> home is a symlink to my Windows home, but this approach would have problems with
> any symlinks along the path to the cygport dir, as $D is not similarly resolved.
Don't do this, at least unless you are never ever using any software
that might also use the same dot-files as Cygwin. Keep your Cygwin home
separate (@work I've made it a subdirectory in my user profile) and use
/etc/fstab.d/user or /etc/nsswicth.conf to make Cygwin mount it.
Regards,
Achim.
--
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+
Factory and User Sound Singles for Waldorf rackAttack:
http://Synth.Stromeko.net/Downloads.html#WaldorfSounds
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: cygport install infinite loop in src_postinstall under __prep_libtool_modules
2020-07-04 20:06 ` Marco Atzeri
@ 2020-07-05 19:29 ` Brian Inglis
0 siblings, 0 replies; 4+ messages in thread
From: Brian Inglis @ 2020-07-05 19:29 UTC (permalink / raw)
To: cygwin-apps
On 2020-07-04 14:06, Marco Atzeri via Cygwin-apps wrote:
> On 04.07.2020 21:35, Brian Inglis wrote:
>> See attached cygport --debug ...cygport install log.
>>
>> Running cygport ... install, src_postinstall under __prep_libtool_modules after
>> "Fixing libtool modules:" does not find dll in:
>>
>> $ find wget2-1.99.2-1.x86_64/ -name 'cygwget*'
>> wget2-1.99.2-1.x86_64/build/libwget/.libs/cygwget-0.dll
>> wget2-1.99.2-1.x86_64/inst/usr/bin/cygwget-0.dll
>>
>> so it loops on /usr/share/cygport/lib/src_postinst.cygpart:1297ff:
>>
>> while [ $(readlink -f ${ltlibdir}/${dlname%/bin/*}) != ${D}$(__host_prefix) ]
>> do
>> dlname=../${dlname}
>> done
>>
>> until readlink returns root and just keeps on going, possibly because my Cygwin
>> home is a symlink to my Windows home, but this approach would have problems with
>> any symlinks along the path to the cygport dir, as $D is not similarly resolved.
>>
>> I can wrap the other path in the condition in $(readlink -f ...) and it works
>> normally but this may not be the best approach here.
>> Alternatives, suggestions?
>>
>> In this pre-package there is a check/test program and a DLL - is there another
>> package I could use as a template for how to split this into two packages?
>>
>
> I assume you are building under some link structure.
> I was hit by long time by it as I was using
>
> /pub -> /cygdrive/d/cyg_pub
> and building in it.
>
> Two options:
>
> 1) patch cygport
>
> I proposed something for that case
> https://sourceware.org/pipermail/cygwin-apps/2020-April/039990.html
>
> 2) mount the directory instead of using links.
> I put this in my fstab and removed the link
>
> d:\cyg_pub /pub NTFS binary,posix=1,nouser 0 0
Thanks for the feedback and suggestions.
You can't mount everywhere you might want to use a symlink.
I have a number of topic and src directories cross-linked for convenience.
I should be able to cd src and run cygport without issues.
[Cygwin directory symlinks have a quirk I don't remember working on any Unix I
tried: after cd src, I can operate on ../tgt where tgt may be a physical sibling
entry in the same directory as src, so is not limited to be an entry in the
logical directory ../ containing the symlink to src.]
My working kludge was:
/usr/share/cygport/lib/src_postinst.cygpart:1295ff:
origdlname=${dlname}
while [ $(readlink -f ${ltlibdir}/${dlname%/bin/*}) !=
$(readlink -f ${D}$(__host_prefix)) ]
do
dlname=../${dlname}
done
but it would have lower overhead as:
origdlname=${dlname}
# do full symlink resolution on both paths compared to avoid issues
local dest_prefix=$(readlink -f ${D}$(__host_prefix))
while [ $(readlink -f ${ltlibdir}/${dlname%/bin/*}) != $dest_prefix ]
do
dlname=../${dlname}
done
I now think curl would be the best template for this package, as it includes
exe, lib, devel, and doc subpackages.
--
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada
This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in IEC units and prefixes, physical quantities in SI.]
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2020-07-05 19:29 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-04 19:35 cygport install infinite loop in src_postinstall under __prep_libtool_modules Brian Inglis
2020-07-04 20:06 ` Marco Atzeri
2020-07-05 19:29 ` Brian Inglis
2020-07-05 5:27 ` ASSI
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).