Update libtool

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
19 messages Options
Reply | Threaded
Open this post in threaded view
|

Update libtool

Rafael Ávila de Espíndola
The last release of libtool is 2.4.6, which is from 2015. We currently
have 2.4.2. I don't expect projects to actually require 2.4.6, but given
how old 2.4.6 is, some check for that version.

Given that libtool is not being developed, the one time pain of updating
to 2.4.6 might be worth it.

This is the first time I try to change anything in ports. What would be
the best way to test this?

Cheers,
Rafael


commit aa84897eb8840f32739b1d61fa5ae230ec8f232e
Author: Rafael Ávila de Espíndola <[hidden email]>
Date:   Tue Sep 22 22:27:59 2020 -0700

    Update libtool
   
    Building sane-backends from git requires libtool 2.4.6. Given that
    libtool 2.4.6 was released in 2015, it seems better to update it in
    ports than try change sane-backends.
   
    Warning: There was quite a bit of cargo cult involved in this. For
    example, I have blindly update the patches and don't know if they are
    still relevant in 2.4.6.

diff --git devel/libtool/Makefile devel/libtool/Makefile
index 0ac0f7a7c0e..5df984bde20 100644
--- devel/libtool/Makefile
+++ devel/libtool/Makefile
@@ -3,7 +3,7 @@
 COMMENT-main= generic shared library support script
 COMMENT-ltdl= GNU libtool system independent dlopen wrapper
 
-VERSION= 2.4.2
+VERSION= 2.4.6
 DISTNAME= libtool-${VERSION}
 PKGNAME-main= ${DISTNAME}
 PKGNAME-ltdl= libltdl-${VERSION}
@@ -22,7 +22,8 @@ MAINTAINER= Brad Smith <[hidden email]>
 PERMIT_PACKAGE= Yes
 
 AUTOCONF_VERSION= 2.67
-BUILD_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
+AUTOMAKE_VERSION= 1.15
+BUILD_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS} ${MODGNU_AUTOMAKE_DEPENDS} devel/m4
 
 MAKE_ENV+= ${_lt_libs}
 MAKE_FLAGS+= ${_lt_libs}
diff --git devel/libtool/distinfo devel/libtool/distinfo
index 3c3ff5143ee..051bc346304 100644
--- devel/libtool/distinfo
+++ devel/libtool/distinfo
@@ -1,2 +1,2 @@
-SHA256 (libtool-2.4.2.tar.gz) = s43kSGKphyk809jfrhxAnVFLbE55TryTZI/r+a/DiRg=
-SIZE (libtool-2.4.2.tar.gz) = 2632347
+SHA256 (libtool-2.4.6.tar.gz) = 471NXT0CWjbCHdavfqgYoq/NTfwepaF7OdeFS80MBuM=
+SIZE (libtool-2.4.6.tar.gz) = 1806697
diff --git devel/libtool/patches/patch-libltdl_config_ltmain_sh devel/libtool/patches/patch-build-aux_ltmain_sh
similarity index 77%
rename from devel/libtool/patches/patch-libltdl_config_ltmain_sh
rename to devel/libtool/patches/patch-build-aux_ltmain_sh
index 848d5a0278e..684c09fe360 100644
--- devel/libtool/patches/patch-libltdl_config_ltmain_sh
+++ devel/libtool/patches/patch-build-aux_ltmain_sh
@@ -1,9 +1,11 @@
-$OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
---- libltdl/config/ltmain.sh.orig Mon Oct 17 06:19:35 2011
-+++ libltdl/config/ltmain.sh Sat Oct 29 07:05:47 2011
-@@ -2714,51 +2714,6 @@ func_mode_finish ()
+$OpenBSD$
+
+Index: build-aux/ltmain.sh
+--- build-aux/ltmain.sh.orig
++++ build-aux/ltmain.sh
+@@ -4033,51 +4033,6 @@ func_mode_finish ()
      # Exit here if they wanted silent mode.
-     $opt_silent && exit $EXIT_SUCCESS
+     $opt_quiet && exit $EXIT_SUCCESS
 
 -    if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
 -      echo "----------------------------------------------------------------------"
@@ -14,27 +16,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
 -      echo
 -      echo "If you ever happen to want to link against installed libraries"
 -      echo "in a given directory, LIBDIR, you must either use libtool, and"
--      echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
+-      echo "specify the full pathname of the library, or use the '-LLIBDIR'"
 -      echo "flag during linking and do at least one of the following:"
 -      if test -n "$shlibpath_var"; then
-- echo "   - add LIBDIR to the \`$shlibpath_var' environment variable"
+- echo "   - add LIBDIR to the '$shlibpath_var' environment variable"
 - echo "     during execution"
 -      fi
 -      if test -n "$runpath_var"; then
-- echo "   - add LIBDIR to the \`$runpath_var' environment variable"
+- echo "   - add LIBDIR to the '$runpath_var' environment variable"
 - echo "     during linking"
 -      fi
 -      if test -n "$hardcode_libdir_flag_spec"; then
 - libdir=LIBDIR
 - eval flag=\"$hardcode_libdir_flag_spec\"
 -
-- $ECHO "   - use the \`$flag' linker flag"
+- $ECHO "   - use the '$flag' linker flag"
 -      fi
 -      if test -n "$admincmds"; then
 - $ECHO "   - have your system administrator run these commands:$admincmds"
 -      fi
 -      if test -f /etc/ld.so.conf; then
-- echo "   - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
+- echo "   - have your system administrator add LIBDIR to '/etc/ld.so.conf'"
 -      fi
 -      echo
 -
@@ -53,7 +55,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
      exit $EXIT_SUCCESS
  }
 
-@@ -2851,6 +2806,10 @@ func_mode_install ()
+@@ -4172,6 +4127,10 @@ func_mode_install ()
        fi
        func_append install_shared_prog " $func_quote_for_eval_result"
      done
@@ -64,25 +66,25 @@ $OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
 
      test -z "$install_prog" && \
        func_fatal_help "you must specify an install program"
-@@ -2988,7 +2947,7 @@ func_mode_install ()
-  test -n "$relink_command" && srcname="$realname"T
+@@ -4309,7 +4268,7 @@ func_mode_install ()
+  test -n "$relink_command" && srcname=${realname}T
 
   # Install the shared library and build the symlinks.
 -  func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
 +  func_show_eval "$install_shared_prog $extra_mode $dir/$srcname $destdir/$realname" \
       'exit $?'
-  tstripme="$stripme"
+  tstripme=$stripme
   case $host_os in
-@@ -3025,7 +2984,7 @@ func_mode_install ()
+@@ -4353,7 +4312,7 @@ func_mode_install ()
  func_basename "$file"
- name="$func_basename_result"
- instname="$dir/$name"i
+ name=$func_basename_result
+ instname=$dir/${name}i
 - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
 + func_show_eval "$install_prog $extra_mode $instname $destdir/$name" 'exit $?'
 
  # Maybe install the static library, too.
  test -n "$old_library" && func_append staticlibs " $dir/$old_library"
-@@ -3060,14 +3019,14 @@ func_mode_install ()
+@@ -4388,14 +4347,14 @@ func_mode_install ()
 
  # Install the libtool object if requested.
  test -n "$destfile" && \
@@ -90,7 +92,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
 +  func_show_eval "$install_prog $extra_mode $file $destfile" 'exit $?'
 
  # Install the old object if enabled.
- if test "$build_old_libs" = yes; then
+ if test yes = "$build_old_libs"; then
   # Deduce the name of the old-style object file.
   func_lo2o "$file"
   staticobj=$func_lo2o_result
@@ -99,7 +101,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
  fi
  exit $EXIT_SUCCESS
  ;;
-@@ -5660,6 +5619,7 @@ func_mode_link ()
+@@ -7075,6 +7034,7 @@ func_mode_link ()
  func_append compiler_flags " $arg"
  func_append compile_command " $arg"
  func_append finalize_command " $arg"
@@ -107,27 +109,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
  case "$new_inherited_linker_flags " in
     *" $arg "*) ;;
     * ) func_append new_inherited_linker_flags " $arg" ;;
-@@ -6167,6 +6127,7 @@ func_mode_link ()
+@@ -7611,6 +7571,7 @@ func_mode_link ()
     finalize_deplibs="$deplib $finalize_deplibs"
   else
     func_append compiler_flags " $deplib"
-+    test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
-    if test "$linkmode" = lib ; then
++        test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
+    if test lib = "$linkmode"; then
  case "$new_inherited_linker_flags " in
     *" $deplib "*) ;;
-@@ -6697,7 +6658,7 @@ func_mode_link ()
+@@ -8140,7 +8101,7 @@ func_mode_link ()
   *)
-    if test "$installed" = no; then
+    if test no = "$installed"; then
       func_append notinst_deplibs " $lib"
 -      need_relink=yes
 +      test -z "$DESTDIR" && need_relink=yes
     fi
     ;;
   esac
-@@ -7521,6 +7482,20 @@ func_mode_link ()
+@@ -9010,6 +8971,20 @@ func_mode_link ()
   major=
   versuffix=
-  verstring=""
+  verstring=
 + else
 +  # XXX
 +  tmp=`echo $libname|sed -e 's,+,_,g' -e 's,-,_,g' -e 's,\.,_,g'`
diff --git devel/libtool/patches/patch-doc_libtool_texi devel/libtool/patches/patch-doc_libtool_texi
index a6fd77281c6..2787889e70a 100644
--- devel/libtool/patches/patch-doc_libtool_texi
+++ devel/libtool/patches/patch-doc_libtool_texi
@@ -1,11 +1,12 @@
 $OpenBSD: patch-doc_libtool_texi,v 1.4 2011/09/22 21:10:19 jasper Exp $
---- doc/libtool.texi.orig Wed Jun  8 11:04:53 2011
-+++ doc/libtool.texi Wed Jun  8 11:05:44 2011
-@@ -11,16 +11,16 @@
- @set MAILLIST the Libtool mailing list @email{libtool@@gnu.org}
- @set objdir .libs
+Index: doc/libtool.texi
+--- doc/libtool.texi.orig
++++ doc/libtool.texi
+@@ -30,15 +30,15 @@ and with no Back-Cover Texts.  A copy of the license i
+ the section entitled ``GNU Free Documentation License''.
+ @end copying
 
--@dircategory GNU programming tools
+-@dircategory Software development
 +@dircategory Programming & development tools
  @direntry
  * Libtool: (libtool).           Generic shared library support script.
@@ -13,11 +14,10 @@ $OpenBSD: patch-doc_libtool_texi,v 1.4 2011/09/22 21:10:19 jasper Exp $
 
  @dircategory Individual utilities
  @direntry
--* libtool-invocation: (libtool)Invoking libtool.
-+* libtool-invocation: (libtool) Invoking libtool.
-                                                 Running the @code{libtool} script.
--* libtoolize: (libtool)Invoking libtoolize.     Adding libtool support.
-+* libtoolize: (libtool) Invoking libtoolize. Adding libtool support.
+-* libtool-invocation: (libtool)Invoking libtool. Running the @code{libtool} script.
+-* libtoolize: (libtool)Invoking libtoolize.      Adding libtool support.
++* libtool-invocation: (libtool) Invoking libtool. Running the @code{libtool} script.
++* libtoolize: (libtool) Invoking libtoolize.      Adding libtool support.
  @end direntry
 
- @ifnottex
+ @titlepage
diff --git devel/libtool/pkg/PLIST-ltdl devel/libtool/pkg/PLIST-ltdl
index f4ba7c94d6a..c470a14b909 100644
--- devel/libtool/pkg/PLIST-ltdl
+++ devel/libtool/pkg/PLIST-ltdl
@@ -10,41 +10,37 @@ lib/libltdl.la
 share/aclocal/
 share/aclocal/ltdl.m4
 share/libtool/
+share/libtool/COPYING.LIB
+share/libtool/Makefile.am
+share/libtool/Makefile.in
+share/libtool/README
+share/libtool/aclocal.m4
+share/libtool/config-h.in
+share/libtool/configure
+share/libtool/configure.ac
 share/libtool/libltdl/
-share/libtool/libltdl/COPYING.LIB
-share/libtool/libltdl/Makefile.am
-share/libtool/libltdl/Makefile.in
-share/libtool/libltdl/Makefile.inc
-share/libtool/libltdl/README
-share/libtool/libltdl/aclocal.m4
-share/libtool/libltdl/argz.c
-share/libtool/libltdl/argz_.h
-share/libtool/libltdl/config-h.in
-share/libtool/libltdl/configure
-share/libtool/libltdl/configure.ac
-share/libtool/libltdl/libltdl/
-share/libtool/libltdl/libltdl/lt__alloc.h
-share/libtool/libltdl/libltdl/lt__dirent.h
-share/libtool/libltdl/libltdl/lt__glibc.h
-share/libtool/libltdl/libltdl/lt__private.h
-share/libtool/libltdl/libltdl/lt__strl.h
-share/libtool/libltdl/libltdl/lt_dlloader.h
-share/libtool/libltdl/libltdl/lt_error.h
-share/libtool/libltdl/libltdl/lt_system.h
-share/libtool/libltdl/libltdl/slist.h
-share/libtool/libltdl/loaders/
-share/libtool/libltdl/loaders/dld_link.c
-share/libtool/libltdl/loaders/dlopen.c
-share/libtool/libltdl/loaders/dyld.c
-share/libtool/libltdl/loaders/load_add_on.c
-share/libtool/libltdl/loaders/loadlibrary.c
-share/libtool/libltdl/loaders/preopen.c
-share/libtool/libltdl/loaders/shl_load.c
-share/libtool/libltdl/lt__alloc.c
-share/libtool/libltdl/lt__dirent.c
-share/libtool/libltdl/lt__strl.c
-share/libtool/libltdl/lt_dlloader.c
-share/libtool/libltdl/lt_error.c
-share/libtool/libltdl/ltdl.c
-share/libtool/libltdl/ltdl.h
-share/libtool/libltdl/slist.c
+share/libtool/libltdl/lt__alloc.h
+share/libtool/libltdl/lt__dirent.h
+share/libtool/libltdl/lt__glibc.h
+share/libtool/libltdl/lt__private.h
+share/libtool/libltdl/lt__strl.h
+share/libtool/libltdl/lt_dlloader.h
+share/libtool/libltdl/lt_error.h
+share/libtool/libltdl/lt_system.h
+share/libtool/libltdl/slist.h
+share/libtool/loaders/
+share/libtool/loaders/dld_link.c
+share/libtool/loaders/dlopen.c
+share/libtool/loaders/dyld.c
+share/libtool/loaders/load_add_on.c
+share/libtool/loaders/loadlibrary.c
+share/libtool/loaders/preopen.c
+share/libtool/loaders/shl_load.c
+share/libtool/lt__alloc.c
+share/libtool/lt__dirent.c
+share/libtool/lt__strl.c
+share/libtool/lt_dlloader.c
+share/libtool/lt_error.c
+share/libtool/ltdl.c
+share/libtool/ltdl.h
+share/libtool/slist.c
diff --git devel/libtool/pkg/PLIST-main devel/libtool/pkg/PLIST-main
index 2ac3d85823e..66ded31a4fd 100644
--- devel/libtool/pkg/PLIST-main
+++ devel/libtool/pkg/PLIST-main
@@ -5,17 +5,17 @@ bin/libtoolize
 @info info/libtool.info
 @man man/man1/libtool.1
 @man man/man1/libtoolize.1
-share/aclocal/argz.m4
+share/aclocal/ltargz.m4
 share/aclocal/libtool.m4
 share/aclocal/ltoptions.m4
 share/aclocal/ltsugar.m4
 share/aclocal/ltversion.m4
 share/aclocal/lt~obsolete.m4
-share/libtool/config/
-share/libtool/config/compile
-share/libtool/config/config.guess
-share/libtool/config/config.sub
-share/libtool/config/depcomp
-share/libtool/config/install-sh
-share/libtool/config/ltmain.sh
-share/libtool/config/missing
+share/libtool/build-aux/
+share/libtool/build-aux/compile
+share/libtool/build-aux/config.guess
+share/libtool/build-aux/config.sub
+share/libtool/build-aux/depcomp
+share/libtool/build-aux/install-sh
+share/libtool/build-aux/ltmain.sh
+share/libtool/build-aux/missing
Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Marc Espie-2
On Mon, Feb 15, 2021 at 01:45:40PM -0800, Rafael Ávila de Espíndola wrote:

> The last release of libtool is 2.4.6, which is from 2015. We currently
> have 2.4.2. I don't expect projects to actually require 2.4.6, but given
> how old 2.4.6 is, some check for that version.
>
> Given that libtool is not being developed, the one time pain of updating
> to 2.4.6 might be worth it.
>
> This is the first time I try to change anything in ports. What would be
> the best way to test this?
>
> Cheers,
> Rafael

For some base stuff like this, the best way to test this is to rebuild
most of everything... so someone who does full builds regularly should test
it.

As for runtime, there are not that many ports depending on ltdl

GraphicsMagick seems like it would be the least painful to check.

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Stuart Henderson
On 2021/02/16 10:09, Marc Espie wrote:

> On Mon, Feb 15, 2021 at 01:45:40PM -0800, Rafael Ávila de Espíndola wrote:
> > The last release of libtool is 2.4.6, which is from 2015. We currently
> > have 2.4.2. I don't expect projects to actually require 2.4.6, but given
> > how old 2.4.6 is, some check for that version.
> >
> > Given that libtool is not being developed, the one time pain of updating
> > to 2.4.6 might be worth it.
> >
> > This is the first time I try to change anything in ports. What would be
> > the best way to test this?
> >
> > Cheers,
> > Rafael
>
> For some base stuff like this, the best way to test this is to rebuild
> most of everything... so someone who does full builds regularly should test
> it.
>
> As for runtime, there are not that many ports depending on ltdl
>
> GraphicsMagick seems like it would be the least painful to check.
>

And there are ports with USE_LIBTOOL=gnu:

audio/pulseaudio # undefined reference to `lt__PROGRAM__LTX_preloaded_symbols'
audio/speech-dispatcher # undefined reference to `lt__PROGRAM__LTX_preloaded_symbols'
cad/tkgate ?
comms/sigrok/libsigrok # /usr/bin/../lib/crt0.o: In function `_start': (.text+0x52): undefined reference to `main'
databases/xapian-bindings # base libtool doesn't support -shrext
devel/bamf # Does not work with base libtool.
devel/openocd # Fails to link main.o and libopenocd.a properly resulting in undefined reference in the gdb_server.o
games/liblcf ?
graphics/libspiro # cc: error: unsupported option '--mode=link'
lang/mono ?
lang/pfe # this renames floating.so to libfloating.so before linking with it
lang/rust # need for libbacktrace
mail/kopano/core ?
net/freeradius # undefined reference to `lt__PROGRAM__LTX_preloaded_symbols'
net/torsocks ?
productivity/aqbanking # ld: error: duplicate symbol: AO_V2_MkOfxHeader
security/fwknop # undefined reference to `fko_new'
security/libotr ?
security/pidgin-otr ?
sysutils/bacula # base libtool with Qt5 is in the too-hard basket
sysutils/collectd # uses -export-symbol-regex
sysutils/nut # -all-static
telephony/siproxd ?
x11/mate/pluma ?

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
In reply to this post by Marc Espie-2
Marc Espie <[hidden email]> writes:

> On Mon, Feb 15, 2021 at 01:45:40PM -0800, Rafael Ávila de Espíndola wrote:
>> The last release of libtool is 2.4.6, which is from 2015. We currently
>> have 2.4.2. I don't expect projects to actually require 2.4.6, but given
>> how old 2.4.6 is, some check for that version.
>>
>> Given that libtool is not being developed, the one time pain of updating
>> to 2.4.6 might be worth it.
>>
>> This is the first time I try to change anything in ports. What would be
>> the best way to test this?
>>
>> Cheers,
>> Rafael
>
> For some base stuff like this, the best way to test this is to rebuild
> most of everything... so someone who does full builds regularly should test
> it.
>
> As for runtime, there are not that many ports depending on ltdl
>
> GraphicsMagick seems like it would be the least painful to check.

I was able to build GraphicsMagick with the new libtool and ltdl and at
least "gm display foo.jpg" works. I only have OpenBSD on a laptop, so
"most of everything" might take too long :-)

Cheers,
Rafael

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Marc Espie-2
On Tue, Feb 16, 2021 at 09:20:20AM -0800, Rafael Ávila de Espíndola wrote:

> Marc Espie <[hidden email]> writes:
>
> > On Mon, Feb 15, 2021 at 01:45:40PM -0800, Rafael Ávila de Espíndola wrote:
> >> The last release of libtool is 2.4.6, which is from 2015. We currently
> >> have 2.4.2. I don't expect projects to actually require 2.4.6, but given
> >> how old 2.4.6 is, some check for that version.
> >>
> >> Given that libtool is not being developed, the one time pain of updating
> >> to 2.4.6 might be worth it.
> >>
> >> This is the first time I try to change anything in ports. What would be
> >> the best way to test this?
> >>
> >> Cheers,
> >> Rafael
> >
> > For some base stuff like this, the best way to test this is to rebuild
> > most of everything... so someone who does full builds regularly should test
> > it.
> >
> > As for runtime, there are not that many ports depending on ltdl
> >
> > GraphicsMagick seems like it would be the least painful to check.
>
> I was able to build GraphicsMagick with the new libtool and ltdl and at
> least "gm display foo.jpg" works. I only have OpenBSD on a laptop, so
> "most of everything" might take too long :-)

Well, there are people who do regular "full builds" of the ports  tree
Of course you're not going to do that with your laptop, the only guys insane
enough to do that are Vadim and Rafael :)

But someone might try your patch and tell you how it goes.

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
In reply to this post by Stuart Henderson
Stuart Henderson <[hidden email]> writes:

> On 2021/02/16 10:09, Marc Espie wrote:
>> On Mon, Feb 15, 2021 at 01:45:40PM -0800, Rafael Ávila de Espíndola wrote:
>> > The last release of libtool is 2.4.6, which is from 2015. We currently
>> > have 2.4.2. I don't expect projects to actually require 2.4.6, but given
>> > how old 2.4.6 is, some check for that version.
>> >
>> > Given that libtool is not being developed, the one time pain of updating
>> > to 2.4.6 might be worth it.
>> >
>> > This is the first time I try to change anything in ports. What would be
>> > the best way to test this?
>> >
>> > Cheers,
>> > Rafael
>>
>> For some base stuff like this, the best way to test this is to rebuild
>> most of everything... so someone who does full builds regularly should test
>> it.
>>
>> As for runtime, there are not that many ports depending on ltdl
>>
>> GraphicsMagick seems like it would be the least painful to check.
>>
>
> And there are ports with USE_LIBTOOL=gnu:

Cool. I have been able to build most of them, and the errors I got don't
look libtool related:

lang/mono:
Fatal: /usr/ports/pobj must be on a wxallowed filesystem (in lang/mono)

lang/rust:
LLVM ERROR: invalid sh_type for string table section [index 34]: expected SHT_STRTAB, but got SHT_NULL

x11/mate/pluma:
Fatal: /usr/ports/pobj must be on a wxallowed filesystem (in x11/mate/pluma)

Cheers,
Rafael

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Sebastien Marie-3
On Wed, Feb 17, 2021 at 01:55:45PM -0800, Rafael Ávila de Espíndola wrote:

> Stuart Henderson <[hidden email]> writes:
> >
> > And there are ports with USE_LIBTOOL=gnu:
>
> Cool. I have been able to build most of them, and the errors I got don't
> look libtool related:
>
> lang/mono:
> Fatal: /usr/ports/pobj must be on a wxallowed filesystem (in lang/mono)
>
> x11/mate/pluma:
> Fatal: /usr/ports/pobj must be on a wxallowed filesystem (in x11/mate/pluma)

These are configuration problem on builder side :)

The partition were /usr/ports/pobj lives needs to be mounted with
wxallowed (at least during the build. you could remove the mount
options after if you don't regulary need it).

See mount(8) man page for what is "wxallowed".


> lang/rust:
> LLVM ERROR: invalid sh_type for string table section [index 34]: expected SHT_STRTAB, but got SHT_NULL

Could you try with the following diff on lang/rust ? It removes the
dependency on libtool. It build fine on -current tree.

-----------------------------------------------
commit 11215898cc759216b6b57348134a8659e5544e32 (master, apollo/master)
from: Sébastien Marie <[hidden email]>
date: Wed Feb 17 05:31:19 2021 UTC
 
 remove libtool, as libbacktrace was gone
 
diff e9c8bbdecc75c1f145efa05a99c3022863e01962 b0ac097d7243f0ed373100d9534d3d4a2bceab6b
blob - 9fa9d60bc79d1376c06dbc7495afb51354599654
blob + c82abb7488e7aa381b4d722e03cfde2894ee7039
--- Makefile
+++ Makefile
@@ -173,9 +173,6 @@ PATCHORIG = .openbsd.orig
 SEPARATE_BUILD = Yes
 USE_GMAKE = Yes
 
-# need for libbacktrace
-USE_LIBTOOL = gnu
-
 TEST_DEPENDS += devel/git \
  sysutils/ggrep
 

Thanks.
--
Sebastien Marie

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
Sebastien Marie <[hidden email]> writes:

> On Wed, Feb 17, 2021 at 01:55:45PM -0800, Rafael Ávila de Espíndola wrote:
>> Stuart Henderson <[hidden email]> writes:
>> >
>> > And there are ports with USE_LIBTOOL=gnu:
>>
>> Cool. I have been able to build most of them, and the errors I got don't
>> look libtool related:
>>
>> lang/mono:
>> Fatal: /usr/ports/pobj must be on a wxallowed filesystem (in lang/mono)
>>
>> x11/mate/pluma:
>> Fatal: /usr/ports/pobj must be on a wxallowed filesystem (in x11/mate/pluma)
>
> These are configuration problem on builder side :)
>
> The partition were /usr/ports/pobj lives needs to be mounted with
> wxallowed (at least during the build. you could remove the mount
> options after if you don't regulary need it).
>
> See mount(8) man page for what is "wxallowed".

Done. Both mono and pluma finished building overnight.

>> lang/rust:
>> LLVM ERROR: invalid sh_type for string table section [index 34]: expected SHT_STRTAB, but got SHT_NULL
>
> Could you try with the following diff on lang/rust ? It removes the
> dependency on libtool. It build fine on -current tree.

Will try it tonight after work.

Thanks,
Rafael

> -----------------------------------------------
> commit 11215898cc759216b6b57348134a8659e5544e32 (master, apollo/master)
> from: Sébastien Marie <[hidden email]>
> date: Wed Feb 17 05:31:19 2021 UTC
>  
>  remove libtool, as libbacktrace was gone
>  
> diff e9c8bbdecc75c1f145efa05a99c3022863e01962 b0ac097d7243f0ed373100d9534d3d4a2bceab6b
> blob - 9fa9d60bc79d1376c06dbc7495afb51354599654
> blob + c82abb7488e7aa381b4d722e03cfde2894ee7039
> --- Makefile
> +++ Makefile
> @@ -173,9 +173,6 @@ PATCHORIG = .openbsd.orig
>  SEPARATE_BUILD = Yes
>  USE_GMAKE = Yes
>  
> -# need for libbacktrace
> -USE_LIBTOOL = gnu
> -
>  TEST_DEPENDS += devel/git \
>   sysutils/ggrep
>  
>
> Thanks.
> --
> Sebastien Marie

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
Rafael Ávila de Espíndola <[hidden email]> writes:

>>> lang/rust:
>>> LLVM ERROR: invalid sh_type for string table section [index 34]: expected SHT_STRTAB, but got SHT_NULL
>>
>> Could you try with the following diff on lang/rust ? It removes the
>> dependency on libtool. It build fine on -current tree.
>
> Will try it tonight after work.

It passes with your patch. I found that odd and tried it again without
the your patch and the build finished fine.

I guess it was just a reliability issue with my laptop.

So in the end I was able to build every package with

USE_LIBTOOL = gnu

Cheers,
Rafael

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Stuart Henderson
I'll do some testing, I'm using this updated diff

Index: Makefile
===================================================================
RCS file: /cvs/ports/devel/libtool/Makefile,v
retrieving revision 1.85
diff -u -p -r1.85 Makefile
--- Makefile 12 Jul 2019 20:44:40 -0000 1.85
+++ Makefile 23 Feb 2021 15:22:13 -0000
@@ -3,12 +3,10 @@
 COMMENT-main= generic shared library support script
 COMMENT-ltdl= GNU libtool system independent dlopen wrapper
 
-VERSION= 2.4.2
+VERSION= 2.4.6
 DISTNAME= libtool-${VERSION}
 PKGNAME-main= ${DISTNAME}
 PKGNAME-ltdl= libltdl-${VERSION}
-REVISION-main= 0
-REVISION-ltdl= 1
 CATEGORIES= devel
 MASTER_SITES= ${MASTER_SITE_GNU:=libtool/}
 
@@ -21,8 +19,9 @@ MAINTAINER= Brad Smith <[hidden email]
 # GPLv2+
 PERMIT_PACKAGE= Yes
 
-AUTOCONF_VERSION= 2.67
-BUILD_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
+AUTOCONF_VERSION= 2.69
+BUILD_DEPENDS= devel/m4
+TEST_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
 
 MAKE_ENV+= ${_lt_libs}
 MAKE_FLAGS+= ${_lt_libs}
@@ -45,6 +44,8 @@ RUN_DEPENDS-main= devel/libtool,-ltdl
 
 pre-configure:
  @cd ${WRKDIR}/bin && ln -sf /usr/bin/true g77
+ cd ${WRKSRC}; \
+ touch -r .version Makefile.in aclocal.m4 m4/ltversion.m4 configure
 
 do-test:
  @cd ${WRKDIR}/bin && ln -sf \
Index: distinfo
===================================================================
RCS file: /cvs/ports/devel/libtool/distinfo,v
retrieving revision 1.16
diff -u -p -r1.16 distinfo
--- distinfo 18 Jan 2015 03:13:17 -0000 1.16
+++ distinfo 23 Feb 2021 15:22:13 -0000
@@ -1,2 +1,2 @@
-SHA256 (libtool-2.4.2.tar.gz) = s43kSGKphyk809jfrhxAnVFLbE55TryTZI/r+a/DiRg=
-SIZE (libtool-2.4.2.tar.gz) = 2632347
+SHA256 (libtool-2.4.6.tar.gz) = 471NXT0CWjbCHdavfqgYoq/NTfwepaF7OdeFS80MBuM=
+SIZE (libtool-2.4.6.tar.gz) = 1806697
Index: patches/patch-doc_libtool_texi
===================================================================
RCS file: /cvs/ports/devel/libtool/patches/patch-doc_libtool_texi,v
retrieving revision 1.4
diff -u -p -r1.4 patch-doc_libtool_texi
--- patches/patch-doc_libtool_texi 22 Sep 2011 21:10:19 -0000 1.4
+++ patches/patch-doc_libtool_texi 23 Feb 2021 15:22:13 -0000
@@ -1,11 +1,12 @@
 $OpenBSD: patch-doc_libtool_texi,v 1.4 2011/09/22 21:10:19 jasper Exp $
---- doc/libtool.texi.orig Wed Jun  8 11:04:53 2011
-+++ doc/libtool.texi Wed Jun  8 11:05:44 2011
-@@ -11,16 +11,16 @@
- @set MAILLIST the Libtool mailing list @email{libtool@@gnu.org}
- @set objdir .libs
+Index: doc/libtool.texi
+--- doc/libtool.texi.orig
++++ doc/libtool.texi
+@@ -30,15 +30,15 @@ and with no Back-Cover Texts.  A copy of the license i
+ the section entitled ``GNU Free Documentation License''.
+ @end copying
 
--@dircategory GNU programming tools
+-@dircategory Software development
 +@dircategory Programming & development tools
  @direntry
  * Libtool: (libtool).           Generic shared library support script.
@@ -13,11 +14,10 @@ $OpenBSD: patch-doc_libtool_texi,v 1.4 2
 
  @dircategory Individual utilities
  @direntry
--* libtool-invocation: (libtool)Invoking libtool.
-+* libtool-invocation: (libtool) Invoking libtool.
-                                                 Running the @code{libtool} script.
--* libtoolize: (libtool)Invoking libtoolize.     Adding libtool support.
-+* libtoolize: (libtool) Invoking libtoolize. Adding libtool support.
+-* libtool-invocation: (libtool)Invoking libtool. Running the @code{libtool} script.
+-* libtoolize: (libtool)Invoking libtoolize.      Adding libtool support.
++* libtool-invocation: (libtool) Invoking libtool. Running the @code{libtool} script.
++* libtoolize: (libtool) Invoking libtoolize.      Adding libtool support.
  @end direntry
 
- @ifnottex
+ @titlepage
Index: patches/patch-libltdl_config_ltmain_sh
===================================================================
RCS file: /cvs/ports/devel/libtool/patches/patch-libltdl_config_ltmain_sh,v
retrieving revision 1.2
diff -u -p -r1.2 patch-libltdl_config_ltmain_sh
--- patches/patch-libltdl_config_ltmain_sh 1 Nov 2011 16:07:31 -0000 1.2
+++ patches/patch-libltdl_config_ltmain_sh 23 Feb 2021 15:22:13 -0000
@@ -1,9 +1,11 @@
-$OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
---- libltdl/config/ltmain.sh.orig Mon Oct 17 06:19:35 2011
-+++ libltdl/config/ltmain.sh Sat Oct 29 07:05:47 2011
-@@ -2714,51 +2714,6 @@ func_mode_finish ()
+$OpenBSD$
+
+Index: build-aux/ltmain.sh
+--- build-aux/ltmain.sh.orig
++++ build-aux/ltmain.sh
+@@ -4033,51 +4033,6 @@ func_mode_finish ()
      # Exit here if they wanted silent mode.
-     $opt_silent && exit $EXIT_SUCCESS
+     $opt_quiet && exit $EXIT_SUCCESS
 
 -    if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
 -      echo "----------------------------------------------------------------------"
@@ -14,27 +16,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
 -      echo
 -      echo "If you ever happen to want to link against installed libraries"
 -      echo "in a given directory, LIBDIR, you must either use libtool, and"
--      echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
+-      echo "specify the full pathname of the library, or use the '-LLIBDIR'"
 -      echo "flag during linking and do at least one of the following:"
 -      if test -n "$shlibpath_var"; then
-- echo "   - add LIBDIR to the \`$shlibpath_var' environment variable"
+- echo "   - add LIBDIR to the '$shlibpath_var' environment variable"
 - echo "     during execution"
 -      fi
 -      if test -n "$runpath_var"; then
-- echo "   - add LIBDIR to the \`$runpath_var' environment variable"
+- echo "   - add LIBDIR to the '$runpath_var' environment variable"
 - echo "     during linking"
 -      fi
 -      if test -n "$hardcode_libdir_flag_spec"; then
 - libdir=LIBDIR
 - eval flag=\"$hardcode_libdir_flag_spec\"
 -
-- $ECHO "   - use the \`$flag' linker flag"
+- $ECHO "   - use the '$flag' linker flag"
 -      fi
 -      if test -n "$admincmds"; then
 - $ECHO "   - have your system administrator run these commands:$admincmds"
 -      fi
 -      if test -f /etc/ld.so.conf; then
-- echo "   - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
+- echo "   - have your system administrator add LIBDIR to '/etc/ld.so.conf'"
 -      fi
 -      echo
 -
@@ -53,7 +55,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
      exit $EXIT_SUCCESS
  }
 
-@@ -2851,6 +2806,10 @@ func_mode_install ()
+@@ -4172,6 +4127,10 @@ func_mode_install ()
        fi
        func_append install_shared_prog " $func_quote_for_eval_result"
      done
@@ -64,25 +66,25 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
 
      test -z "$install_prog" && \
        func_fatal_help "you must specify an install program"
-@@ -2988,7 +2947,7 @@ func_mode_install ()
-  test -n "$relink_command" && srcname="$realname"T
+@@ -4309,7 +4268,7 @@ func_mode_install ()
+  test -n "$relink_command" && srcname=${realname}T
 
   # Install the shared library and build the symlinks.
 -  func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
 +  func_show_eval "$install_shared_prog $extra_mode $dir/$srcname $destdir/$realname" \
       'exit $?'
-  tstripme="$stripme"
+  tstripme=$stripme
   case $host_os in
-@@ -3025,7 +2984,7 @@ func_mode_install ()
+@@ -4353,7 +4312,7 @@ func_mode_install ()
  func_basename "$file"
- name="$func_basename_result"
- instname="$dir/$name"i
+ name=$func_basename_result
+ instname=$dir/${name}i
 - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
 + func_show_eval "$install_prog $extra_mode $instname $destdir/$name" 'exit $?'
 
  # Maybe install the static library, too.
  test -n "$old_library" && func_append staticlibs " $dir/$old_library"
-@@ -3060,14 +3019,14 @@ func_mode_install ()
+@@ -4388,14 +4347,14 @@ func_mode_install ()
 
  # Install the libtool object if requested.
  test -n "$destfile" && \
@@ -90,7 +92,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
 +  func_show_eval "$install_prog $extra_mode $file $destfile" 'exit $?'
 
  # Install the old object if enabled.
- if test "$build_old_libs" = yes; then
+ if test yes = "$build_old_libs"; then
   # Deduce the name of the old-style object file.
   func_lo2o "$file"
   staticobj=$func_lo2o_result
@@ -99,7 +101,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
  fi
  exit $EXIT_SUCCESS
  ;;
-@@ -5660,6 +5619,7 @@ func_mode_link ()
+@@ -7075,6 +7034,7 @@ func_mode_link ()
  func_append compiler_flags " $arg"
  func_append compile_command " $arg"
  func_append finalize_command " $arg"
@@ -107,27 +109,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
  case "$new_inherited_linker_flags " in
     *" $arg "*) ;;
     * ) func_append new_inherited_linker_flags " $arg" ;;
-@@ -6167,6 +6127,7 @@ func_mode_link ()
+@@ -7611,6 +7571,7 @@ func_mode_link ()
     finalize_deplibs="$deplib $finalize_deplibs"
   else
     func_append compiler_flags " $deplib"
-+    test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
-    if test "$linkmode" = lib ; then
++        test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
+    if test lib = "$linkmode"; then
  case "$new_inherited_linker_flags " in
     *" $deplib "*) ;;
-@@ -6697,7 +6658,7 @@ func_mode_link ()
+@@ -8140,7 +8101,7 @@ func_mode_link ()
   *)
-    if test "$installed" = no; then
+    if test no = "$installed"; then
       func_append notinst_deplibs " $lib"
 -      need_relink=yes
 +      test -z "$DESTDIR" && need_relink=yes
     fi
     ;;
   esac
-@@ -7521,6 +7482,20 @@ func_mode_link ()
+@@ -9010,6 +8971,20 @@ func_mode_link ()
   major=
   versuffix=
-  verstring=""
+  verstring=
 + else
 +  # XXX
 +  tmp=`echo $libname|sed -e 's,+,_,g' -e 's,-,_,g' -e 's,\.,_,g'`
Index: pkg/PLIST-ltdl
===================================================================
RCS file: /cvs/ports/devel/libtool/pkg/PLIST-ltdl,v
retrieving revision 1.5
diff -u -p -r1.5 PLIST-ltdl
--- pkg/PLIST-ltdl 19 Mar 2015 20:25:26 -0000 1.5
+++ pkg/PLIST-ltdl 23 Feb 2021 15:22:13 -0000
@@ -4,47 +4,43 @@ include/libltdl/lt_dlloader.h
 include/libltdl/lt_error.h
 include/libltdl/lt_system.h
 include/ltdl.h
-lib/libltdl.a
+@static-lib lib/libltdl.a
 lib/libltdl.la
 @lib lib/libltdl.so.${LIBltdl_VERSION}
 share/aclocal/
 share/aclocal/ltdl.m4
 share/libtool/
+share/libtool/COPYING.LIB
+share/libtool/Makefile.am
+share/libtool/Makefile.in
+share/libtool/README
+share/libtool/aclocal.m4
+share/libtool/config-h.in
+share/libtool/configure
+share/libtool/configure.ac
 share/libtool/libltdl/
-share/libtool/libltdl/COPYING.LIB
-share/libtool/libltdl/Makefile.am
-share/libtool/libltdl/Makefile.in
-share/libtool/libltdl/Makefile.inc
-share/libtool/libltdl/README
-share/libtool/libltdl/aclocal.m4
-share/libtool/libltdl/argz.c
-share/libtool/libltdl/argz_.h
-share/libtool/libltdl/config-h.in
-share/libtool/libltdl/configure
-share/libtool/libltdl/configure.ac
-share/libtool/libltdl/libltdl/
-share/libtool/libltdl/libltdl/lt__alloc.h
-share/libtool/libltdl/libltdl/lt__dirent.h
-share/libtool/libltdl/libltdl/lt__glibc.h
-share/libtool/libltdl/libltdl/lt__private.h
-share/libtool/libltdl/libltdl/lt__strl.h
-share/libtool/libltdl/libltdl/lt_dlloader.h
-share/libtool/libltdl/libltdl/lt_error.h
-share/libtool/libltdl/libltdl/lt_system.h
-share/libtool/libltdl/libltdl/slist.h
-share/libtool/libltdl/loaders/
-share/libtool/libltdl/loaders/dld_link.c
-share/libtool/libltdl/loaders/dlopen.c
-share/libtool/libltdl/loaders/dyld.c
-share/libtool/libltdl/loaders/load_add_on.c
-share/libtool/libltdl/loaders/loadlibrary.c
-share/libtool/libltdl/loaders/preopen.c
-share/libtool/libltdl/loaders/shl_load.c
-share/libtool/libltdl/lt__alloc.c
-share/libtool/libltdl/lt__dirent.c
-share/libtool/libltdl/lt__strl.c
-share/libtool/libltdl/lt_dlloader.c
-share/libtool/libltdl/lt_error.c
-share/libtool/libltdl/ltdl.c
-share/libtool/libltdl/ltdl.h
-share/libtool/libltdl/slist.c
+share/libtool/libltdl/lt__alloc.h
+share/libtool/libltdl/lt__dirent.h
+share/libtool/libltdl/lt__glibc.h
+share/libtool/libltdl/lt__private.h
+share/libtool/libltdl/lt__strl.h
+share/libtool/libltdl/lt_dlloader.h
+share/libtool/libltdl/lt_error.h
+share/libtool/libltdl/lt_system.h
+share/libtool/libltdl/slist.h
+share/libtool/loaders/
+share/libtool/loaders/dld_link.c
+share/libtool/loaders/dlopen.c
+share/libtool/loaders/dyld.c
+share/libtool/loaders/load_add_on.c
+share/libtool/loaders/loadlibrary.c
+share/libtool/loaders/preopen.c
+share/libtool/loaders/shl_load.c
+share/libtool/lt__alloc.c
+share/libtool/lt__dirent.c
+share/libtool/lt__strl.c
+share/libtool/lt_dlloader.c
+share/libtool/lt_error.c
+share/libtool/ltdl.c
+share/libtool/ltdl.h
+share/libtool/slist.c
Index: pkg/PLIST-main
===================================================================
RCS file: /cvs/ports/devel/libtool/pkg/PLIST-main,v
retrieving revision 1.2
diff -u -p -r1.2 PLIST-main
--- pkg/PLIST-main 22 Sep 2011 21:10:19 -0000 1.2
+++ pkg/PLIST-main 23 Feb 2021 15:22:13 -0000
@@ -5,17 +5,20 @@ bin/libtoolize
 @info info/libtool.info
 @man man/man1/libtool.1
 @man man/man1/libtoolize.1
-share/aclocal/argz.m4
 share/aclocal/libtool.m4
+share/aclocal/ltargz.m4
 share/aclocal/ltoptions.m4
 share/aclocal/ltsugar.m4
 share/aclocal/ltversion.m4
 share/aclocal/lt~obsolete.m4
-share/libtool/config/
-share/libtool/config/compile
-share/libtool/config/config.guess
-share/libtool/config/config.sub
-share/libtool/config/depcomp
-share/libtool/config/install-sh
-share/libtool/config/ltmain.sh
-share/libtool/config/missing
+share/libtool/build-aux/
+share/libtool/build-aux/compile
+share/libtool/build-aux/config.guess
+share/libtool/build-aux/config.sub
+share/libtool/build-aux/depcomp
+share/libtool/build-aux/install-sh
+share/libtool/build-aux/ltmain.sh
+share/libtool/build-aux/missing
+share/libtool/libltdl/lt__argz_.h
+share/libtool/lt__argz.c
+share/libtool/ltdl.mk

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
Thanks!

I see that you added

 touch -r .version Makefile.in aclocal.m4 m4/ltversion.m4 configure

Which I assume is to prevent make from trying to recreate those files. I
also see that you upgraded autoconf:

AUTOCONF_VERSION= 2.69

But given the "touch", is autoconf still needed?

Thanks,
Rafael

Stuart Henderson <[hidden email]> writes:

> I'll do some testing, I'm using this updated diff
>
> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/Makefile,v
> retrieving revision 1.85
> diff -u -p -r1.85 Makefile
> --- Makefile 12 Jul 2019 20:44:40 -0000 1.85
> +++ Makefile 23 Feb 2021 15:22:13 -0000
> @@ -3,12 +3,10 @@
>  COMMENT-main= generic shared library support script
>  COMMENT-ltdl= GNU libtool system independent dlopen wrapper
>  
> -VERSION= 2.4.2
> +VERSION= 2.4.6
>  DISTNAME= libtool-${VERSION}
>  PKGNAME-main= ${DISTNAME}
>  PKGNAME-ltdl= libltdl-${VERSION}
> -REVISION-main= 0
> -REVISION-ltdl= 1
>  CATEGORIES= devel
>  MASTER_SITES= ${MASTER_SITE_GNU:=libtool/}
>  
> @@ -21,8 +19,9 @@ MAINTAINER= Brad Smith <[hidden email]
>  # GPLv2+
>  PERMIT_PACKAGE= Yes
>  
> -AUTOCONF_VERSION= 2.67
> -BUILD_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
> +AUTOCONF_VERSION= 2.69
> +BUILD_DEPENDS= devel/m4
> +TEST_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
>  
>  MAKE_ENV+= ${_lt_libs}
>  MAKE_FLAGS+= ${_lt_libs}
> @@ -45,6 +44,8 @@ RUN_DEPENDS-main= devel/libtool,-ltdl
>  
>  pre-configure:
>   @cd ${WRKDIR}/bin && ln -sf /usr/bin/true g77
> + cd ${WRKSRC}; \
> + touch -r .version Makefile.in aclocal.m4 m4/ltversion.m4 configure
>  
>  do-test:
>   @cd ${WRKDIR}/bin && ln -sf \
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/distinfo,v
> retrieving revision 1.16
> diff -u -p -r1.16 distinfo
> --- distinfo 18 Jan 2015 03:13:17 -0000 1.16
> +++ distinfo 23 Feb 2021 15:22:13 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (libtool-2.4.2.tar.gz) = s43kSGKphyk809jfrhxAnVFLbE55TryTZI/r+a/DiRg=
> -SIZE (libtool-2.4.2.tar.gz) = 2632347
> +SHA256 (libtool-2.4.6.tar.gz) = 471NXT0CWjbCHdavfqgYoq/NTfwepaF7OdeFS80MBuM=
> +SIZE (libtool-2.4.6.tar.gz) = 1806697
> Index: patches/patch-doc_libtool_texi
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/patches/patch-doc_libtool_texi,v
> retrieving revision 1.4
> diff -u -p -r1.4 patch-doc_libtool_texi
> --- patches/patch-doc_libtool_texi 22 Sep 2011 21:10:19 -0000 1.4
> +++ patches/patch-doc_libtool_texi 23 Feb 2021 15:22:13 -0000
> @@ -1,11 +1,12 @@
>  $OpenBSD: patch-doc_libtool_texi,v 1.4 2011/09/22 21:10:19 jasper Exp $
> ---- doc/libtool.texi.orig Wed Jun  8 11:04:53 2011
> -+++ doc/libtool.texi Wed Jun  8 11:05:44 2011
> -@@ -11,16 +11,16 @@
> - @set MAILLIST the Libtool mailing list @email{libtool@@gnu.org}
> - @set objdir .libs
> +Index: doc/libtool.texi
> +--- doc/libtool.texi.orig
> ++++ doc/libtool.texi
> +@@ -30,15 +30,15 @@ and with no Back-Cover Texts.  A copy of the license i
> + the section entitled ``GNU Free Documentation License''.
> + @end copying
>  
> --@dircategory GNU programming tools
> +-@dircategory Software development
>  +@dircategory Programming & development tools
>   @direntry
>   * Libtool: (libtool).           Generic shared library support script.
> @@ -13,11 +14,10 @@ $OpenBSD: patch-doc_libtool_texi,v 1.4 2
>  
>   @dircategory Individual utilities
>   @direntry
> --* libtool-invocation: (libtool)Invoking libtool.
> -+* libtool-invocation: (libtool) Invoking libtool.
> -                                                 Running the @code{libtool} script.
> --* libtoolize: (libtool)Invoking libtoolize.     Adding libtool support.
> -+* libtoolize: (libtool) Invoking libtoolize. Adding libtool support.
> +-* libtool-invocation: (libtool)Invoking libtool. Running the @code{libtool} script.
> +-* libtoolize: (libtool)Invoking libtoolize.      Adding libtool support.
> ++* libtool-invocation: (libtool) Invoking libtool. Running the @code{libtool} script.
> ++* libtoolize: (libtool) Invoking libtoolize.      Adding libtool support.
>   @end direntry
>  
> - @ifnottex
> + @titlepage
> Index: patches/patch-libltdl_config_ltmain_sh
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/patches/patch-libltdl_config_ltmain_sh,v
> retrieving revision 1.2
> diff -u -p -r1.2 patch-libltdl_config_ltmain_sh
> --- patches/patch-libltdl_config_ltmain_sh 1 Nov 2011 16:07:31 -0000 1.2
> +++ patches/patch-libltdl_config_ltmain_sh 23 Feb 2021 15:22:13 -0000
> @@ -1,9 +1,11 @@
> -$OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
> ---- libltdl/config/ltmain.sh.orig Mon Oct 17 06:19:35 2011
> -+++ libltdl/config/ltmain.sh Sat Oct 29 07:05:47 2011
> -@@ -2714,51 +2714,6 @@ func_mode_finish ()
> +$OpenBSD$
> +
> +Index: build-aux/ltmain.sh
> +--- build-aux/ltmain.sh.orig
> ++++ build-aux/ltmain.sh
> +@@ -4033,51 +4033,6 @@ func_mode_finish ()
>       # Exit here if they wanted silent mode.
> -     $opt_silent && exit $EXIT_SUCCESS
> +     $opt_quiet && exit $EXIT_SUCCESS
>  
>  -    if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
>  -      echo "----------------------------------------------------------------------"
> @@ -14,27 +16,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>  -      echo
>  -      echo "If you ever happen to want to link against installed libraries"
>  -      echo "in a given directory, LIBDIR, you must either use libtool, and"
> --      echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
> +-      echo "specify the full pathname of the library, or use the '-LLIBDIR'"
>  -      echo "flag during linking and do at least one of the following:"
>  -      if test -n "$shlibpath_var"; then
> -- echo "   - add LIBDIR to the \`$shlibpath_var' environment variable"
> +- echo "   - add LIBDIR to the '$shlibpath_var' environment variable"
>  - echo "     during execution"
>  -      fi
>  -      if test -n "$runpath_var"; then
> -- echo "   - add LIBDIR to the \`$runpath_var' environment variable"
> +- echo "   - add LIBDIR to the '$runpath_var' environment variable"
>  - echo "     during linking"
>  -      fi
>  -      if test -n "$hardcode_libdir_flag_spec"; then
>  - libdir=LIBDIR
>  - eval flag=\"$hardcode_libdir_flag_spec\"
>  -
> -- $ECHO "   - use the \`$flag' linker flag"
> +- $ECHO "   - use the '$flag' linker flag"
>  -      fi
>  -      if test -n "$admincmds"; then
>  - $ECHO "   - have your system administrator run these commands:$admincmds"
>  -      fi
>  -      if test -f /etc/ld.so.conf; then
> -- echo "   - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
> +- echo "   - have your system administrator add LIBDIR to '/etc/ld.so.conf'"
>  -      fi
>  -      echo
>  -
> @@ -53,7 +55,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>       exit $EXIT_SUCCESS
>   }
>  
> -@@ -2851,6 +2806,10 @@ func_mode_install ()
> +@@ -4172,6 +4127,10 @@ func_mode_install ()
>         fi
>         func_append install_shared_prog " $func_quote_for_eval_result"
>       done
> @@ -64,25 +66,25 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>  
>       test -z "$install_prog" && \
>         func_fatal_help "you must specify an install program"
> -@@ -2988,7 +2947,7 @@ func_mode_install ()
> -  test -n "$relink_command" && srcname="$realname"T
> +@@ -4309,7 +4268,7 @@ func_mode_install ()
> +  test -n "$relink_command" && srcname=${realname}T
>  
>    # Install the shared library and build the symlinks.
>  -  func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
>  +  func_show_eval "$install_shared_prog $extra_mode $dir/$srcname $destdir/$realname" \
>        'exit $?'
> -  tstripme="$stripme"
> +  tstripme=$stripme
>    case $host_os in
> -@@ -3025,7 +2984,7 @@ func_mode_install ()
> +@@ -4353,7 +4312,7 @@ func_mode_install ()
>   func_basename "$file"
> - name="$func_basename_result"
> - instname="$dir/$name"i
> + name=$func_basename_result
> + instname=$dir/${name}i
>  - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
>  + func_show_eval "$install_prog $extra_mode $instname $destdir/$name" 'exit $?'
>  
>   # Maybe install the static library, too.
>   test -n "$old_library" && func_append staticlibs " $dir/$old_library"
> -@@ -3060,14 +3019,14 @@ func_mode_install ()
> +@@ -4388,14 +4347,14 @@ func_mode_install ()
>  
>   # Install the libtool object if requested.
>   test -n "$destfile" && \
> @@ -90,7 +92,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>  +  func_show_eval "$install_prog $extra_mode $file $destfile" 'exit $?'
>  
>   # Install the old object if enabled.
> - if test "$build_old_libs" = yes; then
> + if test yes = "$build_old_libs"; then
>    # Deduce the name of the old-style object file.
>    func_lo2o "$file"
>    staticobj=$func_lo2o_result
> @@ -99,7 +101,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>   fi
>   exit $EXIT_SUCCESS
>   ;;
> -@@ -5660,6 +5619,7 @@ func_mode_link ()
> +@@ -7075,6 +7034,7 @@ func_mode_link ()
>   func_append compiler_flags " $arg"
>   func_append compile_command " $arg"
>   func_append finalize_command " $arg"
> @@ -107,27 +109,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>   case "$new_inherited_linker_flags " in
>      *" $arg "*) ;;
>      * ) func_append new_inherited_linker_flags " $arg" ;;
> -@@ -6167,6 +6127,7 @@ func_mode_link ()
> +@@ -7611,6 +7571,7 @@ func_mode_link ()
>      finalize_deplibs="$deplib $finalize_deplibs"
>    else
>      func_append compiler_flags " $deplib"
> -+    test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
> -    if test "$linkmode" = lib ; then
> ++        test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
> +    if test lib = "$linkmode"; then
>   case "$new_inherited_linker_flags " in
>      *" $deplib "*) ;;
> -@@ -6697,7 +6658,7 @@ func_mode_link ()
> +@@ -8140,7 +8101,7 @@ func_mode_link ()
>    *)
> -    if test "$installed" = no; then
> +    if test no = "$installed"; then
>        func_append notinst_deplibs " $lib"
>  -      need_relink=yes
>  +      test -z "$DESTDIR" && need_relink=yes
>      fi
>      ;;
>    esac
> -@@ -7521,6 +7482,20 @@ func_mode_link ()
> +@@ -9010,6 +8971,20 @@ func_mode_link ()
>    major=
>    versuffix=
> -  verstring=""
> +  verstring=
>  + else
>  +  # XXX
>  +  tmp=`echo $libname|sed -e 's,+,_,g' -e 's,-,_,g' -e 's,\.,_,g'`
> Index: pkg/PLIST-ltdl
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/pkg/PLIST-ltdl,v
> retrieving revision 1.5
> diff -u -p -r1.5 PLIST-ltdl
> --- pkg/PLIST-ltdl 19 Mar 2015 20:25:26 -0000 1.5
> +++ pkg/PLIST-ltdl 23 Feb 2021 15:22:13 -0000
> @@ -4,47 +4,43 @@ include/libltdl/lt_dlloader.h
>  include/libltdl/lt_error.h
>  include/libltdl/lt_system.h
>  include/ltdl.h
> -lib/libltdl.a
> +@static-lib lib/libltdl.a
>  lib/libltdl.la
>  @lib lib/libltdl.so.${LIBltdl_VERSION}
>  share/aclocal/
>  share/aclocal/ltdl.m4
>  share/libtool/
> +share/libtool/COPYING.LIB
> +share/libtool/Makefile.am
> +share/libtool/Makefile.in
> +share/libtool/README
> +share/libtool/aclocal.m4
> +share/libtool/config-h.in
> +share/libtool/configure
> +share/libtool/configure.ac
>  share/libtool/libltdl/
> -share/libtool/libltdl/COPYING.LIB
> -share/libtool/libltdl/Makefile.am
> -share/libtool/libltdl/Makefile.in
> -share/libtool/libltdl/Makefile.inc
> -share/libtool/libltdl/README
> -share/libtool/libltdl/aclocal.m4
> -share/libtool/libltdl/argz.c
> -share/libtool/libltdl/argz_.h
> -share/libtool/libltdl/config-h.in
> -share/libtool/libltdl/configure
> -share/libtool/libltdl/configure.ac
> -share/libtool/libltdl/libltdl/
> -share/libtool/libltdl/libltdl/lt__alloc.h
> -share/libtool/libltdl/libltdl/lt__dirent.h
> -share/libtool/libltdl/libltdl/lt__glibc.h
> -share/libtool/libltdl/libltdl/lt__private.h
> -share/libtool/libltdl/libltdl/lt__strl.h
> -share/libtool/libltdl/libltdl/lt_dlloader.h
> -share/libtool/libltdl/libltdl/lt_error.h
> -share/libtool/libltdl/libltdl/lt_system.h
> -share/libtool/libltdl/libltdl/slist.h
> -share/libtool/libltdl/loaders/
> -share/libtool/libltdl/loaders/dld_link.c
> -share/libtool/libltdl/loaders/dlopen.c
> -share/libtool/libltdl/loaders/dyld.c
> -share/libtool/libltdl/loaders/load_add_on.c
> -share/libtool/libltdl/loaders/loadlibrary.c
> -share/libtool/libltdl/loaders/preopen.c
> -share/libtool/libltdl/loaders/shl_load.c
> -share/libtool/libltdl/lt__alloc.c
> -share/libtool/libltdl/lt__dirent.c
> -share/libtool/libltdl/lt__strl.c
> -share/libtool/libltdl/lt_dlloader.c
> -share/libtool/libltdl/lt_error.c
> -share/libtool/libltdl/ltdl.c
> -share/libtool/libltdl/ltdl.h
> -share/libtool/libltdl/slist.c
> +share/libtool/libltdl/lt__alloc.h
> +share/libtool/libltdl/lt__dirent.h
> +share/libtool/libltdl/lt__glibc.h
> +share/libtool/libltdl/lt__private.h
> +share/libtool/libltdl/lt__strl.h
> +share/libtool/libltdl/lt_dlloader.h
> +share/libtool/libltdl/lt_error.h
> +share/libtool/libltdl/lt_system.h
> +share/libtool/libltdl/slist.h
> +share/libtool/loaders/
> +share/libtool/loaders/dld_link.c
> +share/libtool/loaders/dlopen.c
> +share/libtool/loaders/dyld.c
> +share/libtool/loaders/load_add_on.c
> +share/libtool/loaders/loadlibrary.c
> +share/libtool/loaders/preopen.c
> +share/libtool/loaders/shl_load.c
> +share/libtool/lt__alloc.c
> +share/libtool/lt__dirent.c
> +share/libtool/lt__strl.c
> +share/libtool/lt_dlloader.c
> +share/libtool/lt_error.c
> +share/libtool/ltdl.c
> +share/libtool/ltdl.h
> +share/libtool/slist.c
> Index: pkg/PLIST-main
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/pkg/PLIST-main,v
> retrieving revision 1.2
> diff -u -p -r1.2 PLIST-main
> --- pkg/PLIST-main 22 Sep 2011 21:10:19 -0000 1.2
> +++ pkg/PLIST-main 23 Feb 2021 15:22:13 -0000
> @@ -5,17 +5,20 @@ bin/libtoolize
>  @info info/libtool.info
>  @man man/man1/libtool.1
>  @man man/man1/libtoolize.1
> -share/aclocal/argz.m4
>  share/aclocal/libtool.m4
> +share/aclocal/ltargz.m4
>  share/aclocal/ltoptions.m4
>  share/aclocal/ltsugar.m4
>  share/aclocal/ltversion.m4
>  share/aclocal/lt~obsolete.m4
> -share/libtool/config/
> -share/libtool/config/compile
> -share/libtool/config/config.guess
> -share/libtool/config/config.sub
> -share/libtool/config/depcomp
> -share/libtool/config/install-sh
> -share/libtool/config/ltmain.sh
> -share/libtool/config/missing
> +share/libtool/build-aux/
> +share/libtool/build-aux/compile
> +share/libtool/build-aux/config.guess
> +share/libtool/build-aux/config.sub
> +share/libtool/build-aux/depcomp
> +share/libtool/build-aux/install-sh
> +share/libtool/build-aux/ltmain.sh
> +share/libtool/build-aux/missing
> +share/libtool/libltdl/lt__argz_.h
> +share/libtool/lt__argz.c
> +share/libtool/ltdl.mk

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Stuart Henderson
On 2021/02/23 07:44, Rafael Ávila de Espíndola wrote:
> Thanks!
>
> I see that you added
>
>  touch -r .version Makefile.in aclocal.m4 m4/ltversion.m4 configure
>
> Which I assume is to prevent make from trying to recreate those files. I
> also see that you upgraded autoconf:

Yes, it happens because the timestamps in the distfile were out of order.
I added -dm to MAKE_FLAGS while I was figuring this out. None of the
patches in the port touch autoconf/automake input files so this is ok.

> AUTOCONF_VERSION= 2.69
>
> But given the "touch", is autoconf still needed?

It's needed for tests, I moved it to TEST_DEPENDS as well. (I made sure
that those still work when libtool is configured/built with autoconf
not present).

Re AUTOCONF_VERSION, I checked the version of the bundled generated
configure script and set the same, this is usually the best method for
ports.

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola

Stuart Henderson <[hidden email]> writes:

> On 2021/02/23 07:44, Rafael Ávila de Espíndola wrote:
>> Thanks!
>>
>> I see that you added
>>
>>  touch -r .version Makefile.in aclocal.m4 m4/ltversion.m4 configure
>>
>> Which I assume is to prevent make from trying to recreate those files. I
>> also see that you upgraded autoconf:
>
> Yes, it happens because the timestamps in the distfile were out of order.
> I added -dm to MAKE_FLAGS while I was figuring this out. None of the
> patches in the port touch autoconf/automake input files so this is ok.
>
>> AUTOCONF_VERSION= 2.69
>>
>> But given the "touch", is autoconf still needed?
>
> It's needed for tests, I moved it to TEST_DEPENDS as well. (I made sure
> that those still work when libtool is configured/built with autoconf
> not present).
>
> Re AUTOCONF_VERSION, I checked the version of the bundled generated
> configure script and set the same, this is usually the best method for
> ports.

Makes sense. Thanks for the tips.

Cheers,
Rafael

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Stuart Henderson
In reply to this post by Stuart Henderson
On 2021/02/23 15:25, Stuart Henderson wrote:
> I'll do some testing, I'm using this updated diff

Oh yuk, gnu m4 is now needed at runtime for libtoolize.
Is there a way around that?

> Index: Makefile
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/Makefile,v
> retrieving revision 1.85
> diff -u -p -r1.85 Makefile
> --- Makefile 12 Jul 2019 20:44:40 -0000 1.85
> +++ Makefile 23 Feb 2021 15:22:13 -0000
> @@ -3,12 +3,10 @@
>  COMMENT-main= generic shared library support script
>  COMMENT-ltdl= GNU libtool system independent dlopen wrapper
>  
> -VERSION= 2.4.2
> +VERSION= 2.4.6
>  DISTNAME= libtool-${VERSION}
>  PKGNAME-main= ${DISTNAME}
>  PKGNAME-ltdl= libltdl-${VERSION}
> -REVISION-main= 0
> -REVISION-ltdl= 1
>  CATEGORIES= devel
>  MASTER_SITES= ${MASTER_SITE_GNU:=libtool/}
>  
> @@ -21,8 +19,9 @@ MAINTAINER= Brad Smith <[hidden email]
>  # GPLv2+
>  PERMIT_PACKAGE= Yes
>  
> -AUTOCONF_VERSION= 2.67
> -BUILD_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
> +AUTOCONF_VERSION= 2.69
> +BUILD_DEPENDS= devel/m4
> +TEST_DEPENDS= ${MODGNU_AUTOCONF_DEPENDS}
>  
>  MAKE_ENV+= ${_lt_libs}
>  MAKE_FLAGS+= ${_lt_libs}
> @@ -45,6 +44,8 @@ RUN_DEPENDS-main= devel/libtool,-ltdl
>  
>  pre-configure:
>   @cd ${WRKDIR}/bin && ln -sf /usr/bin/true g77
> + cd ${WRKSRC}; \
> + touch -r .version Makefile.in aclocal.m4 m4/ltversion.m4 configure
>  
>  do-test:
>   @cd ${WRKDIR}/bin && ln -sf \
> Index: distinfo
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/distinfo,v
> retrieving revision 1.16
> diff -u -p -r1.16 distinfo
> --- distinfo 18 Jan 2015 03:13:17 -0000 1.16
> +++ distinfo 23 Feb 2021 15:22:13 -0000
> @@ -1,2 +1,2 @@
> -SHA256 (libtool-2.4.2.tar.gz) = s43kSGKphyk809jfrhxAnVFLbE55TryTZI/r+a/DiRg=
> -SIZE (libtool-2.4.2.tar.gz) = 2632347
> +SHA256 (libtool-2.4.6.tar.gz) = 471NXT0CWjbCHdavfqgYoq/NTfwepaF7OdeFS80MBuM=
> +SIZE (libtool-2.4.6.tar.gz) = 1806697
> Index: patches/patch-doc_libtool_texi
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/patches/patch-doc_libtool_texi,v
> retrieving revision 1.4
> diff -u -p -r1.4 patch-doc_libtool_texi
> --- patches/patch-doc_libtool_texi 22 Sep 2011 21:10:19 -0000 1.4
> +++ patches/patch-doc_libtool_texi 23 Feb 2021 15:22:13 -0000
> @@ -1,11 +1,12 @@
>  $OpenBSD: patch-doc_libtool_texi,v 1.4 2011/09/22 21:10:19 jasper Exp $
> ---- doc/libtool.texi.orig Wed Jun  8 11:04:53 2011
> -+++ doc/libtool.texi Wed Jun  8 11:05:44 2011
> -@@ -11,16 +11,16 @@
> - @set MAILLIST the Libtool mailing list @email{libtool@@gnu.org}
> - @set objdir .libs
> +Index: doc/libtool.texi
> +--- doc/libtool.texi.orig
> ++++ doc/libtool.texi
> +@@ -30,15 +30,15 @@ and with no Back-Cover Texts.  A copy of the license i
> + the section entitled ``GNU Free Documentation License''.
> + @end copying
>  
> --@dircategory GNU programming tools
> +-@dircategory Software development
>  +@dircategory Programming & development tools
>   @direntry
>   * Libtool: (libtool).           Generic shared library support script.
> @@ -13,11 +14,10 @@ $OpenBSD: patch-doc_libtool_texi,v 1.4 2
>  
>   @dircategory Individual utilities
>   @direntry
> --* libtool-invocation: (libtool)Invoking libtool.
> -+* libtool-invocation: (libtool) Invoking libtool.
> -                                                 Running the @code{libtool} script.
> --* libtoolize: (libtool)Invoking libtoolize.     Adding libtool support.
> -+* libtoolize: (libtool) Invoking libtoolize. Adding libtool support.
> +-* libtool-invocation: (libtool)Invoking libtool. Running the @code{libtool} script.
> +-* libtoolize: (libtool)Invoking libtoolize.      Adding libtool support.
> ++* libtool-invocation: (libtool) Invoking libtool. Running the @code{libtool} script.
> ++* libtoolize: (libtool) Invoking libtoolize.      Adding libtool support.
>   @end direntry
>  
> - @ifnottex
> + @titlepage
> Index: patches/patch-libltdl_config_ltmain_sh
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/patches/patch-libltdl_config_ltmain_sh,v
> retrieving revision 1.2
> diff -u -p -r1.2 patch-libltdl_config_ltmain_sh
> --- patches/patch-libltdl_config_ltmain_sh 1 Nov 2011 16:07:31 -0000 1.2
> +++ patches/patch-libltdl_config_ltmain_sh 23 Feb 2021 15:22:13 -0000
> @@ -1,9 +1,11 @@
> -$OpenBSD: patch-libltdl_config_ltmain_sh,v 1.2 2011/11/01 16:07:31 jasper Exp $
> ---- libltdl/config/ltmain.sh.orig Mon Oct 17 06:19:35 2011
> -+++ libltdl/config/ltmain.sh Sat Oct 29 07:05:47 2011
> -@@ -2714,51 +2714,6 @@ func_mode_finish ()
> +$OpenBSD$
> +
> +Index: build-aux/ltmain.sh
> +--- build-aux/ltmain.sh.orig
> ++++ build-aux/ltmain.sh
> +@@ -4033,51 +4033,6 @@ func_mode_finish ()
>       # Exit here if they wanted silent mode.
> -     $opt_silent && exit $EXIT_SUCCESS
> +     $opt_quiet && exit $EXIT_SUCCESS
>  
>  -    if test -n "$finish_cmds$finish_eval" && test -n "$libdirs"; then
>  -      echo "----------------------------------------------------------------------"
> @@ -14,27 +16,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>  -      echo
>  -      echo "If you ever happen to want to link against installed libraries"
>  -      echo "in a given directory, LIBDIR, you must either use libtool, and"
> --      echo "specify the full pathname of the library, or use the \`-LLIBDIR'"
> +-      echo "specify the full pathname of the library, or use the '-LLIBDIR'"
>  -      echo "flag during linking and do at least one of the following:"
>  -      if test -n "$shlibpath_var"; then
> -- echo "   - add LIBDIR to the \`$shlibpath_var' environment variable"
> +- echo "   - add LIBDIR to the '$shlibpath_var' environment variable"
>  - echo "     during execution"
>  -      fi
>  -      if test -n "$runpath_var"; then
> -- echo "   - add LIBDIR to the \`$runpath_var' environment variable"
> +- echo "   - add LIBDIR to the '$runpath_var' environment variable"
>  - echo "     during linking"
>  -      fi
>  -      if test -n "$hardcode_libdir_flag_spec"; then
>  - libdir=LIBDIR
>  - eval flag=\"$hardcode_libdir_flag_spec\"
>  -
> -- $ECHO "   - use the \`$flag' linker flag"
> +- $ECHO "   - use the '$flag' linker flag"
>  -      fi
>  -      if test -n "$admincmds"; then
>  - $ECHO "   - have your system administrator run these commands:$admincmds"
>  -      fi
>  -      if test -f /etc/ld.so.conf; then
> -- echo "   - have your system administrator add LIBDIR to \`/etc/ld.so.conf'"
> +- echo "   - have your system administrator add LIBDIR to '/etc/ld.so.conf'"
>  -      fi
>  -      echo
>  -
> @@ -53,7 +55,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>       exit $EXIT_SUCCESS
>   }
>  
> -@@ -2851,6 +2806,10 @@ func_mode_install ()
> +@@ -4172,6 +4127,10 @@ func_mode_install ()
>         fi
>         func_append install_shared_prog " $func_quote_for_eval_result"
>       done
> @@ -64,25 +66,25 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>  
>       test -z "$install_prog" && \
>         func_fatal_help "you must specify an install program"
> -@@ -2988,7 +2947,7 @@ func_mode_install ()
> -  test -n "$relink_command" && srcname="$realname"T
> +@@ -4309,7 +4268,7 @@ func_mode_install ()
> +  test -n "$relink_command" && srcname=${realname}T
>  
>    # Install the shared library and build the symlinks.
>  -  func_show_eval "$install_shared_prog $dir/$srcname $destdir/$realname" \
>  +  func_show_eval "$install_shared_prog $extra_mode $dir/$srcname $destdir/$realname" \
>        'exit $?'
> -  tstripme="$stripme"
> +  tstripme=$stripme
>    case $host_os in
> -@@ -3025,7 +2984,7 @@ func_mode_install ()
> +@@ -4353,7 +4312,7 @@ func_mode_install ()
>   func_basename "$file"
> - name="$func_basename_result"
> - instname="$dir/$name"i
> + name=$func_basename_result
> + instname=$dir/${name}i
>  - func_show_eval "$install_prog $instname $destdir/$name" 'exit $?'
>  + func_show_eval "$install_prog $extra_mode $instname $destdir/$name" 'exit $?'
>  
>   # Maybe install the static library, too.
>   test -n "$old_library" && func_append staticlibs " $dir/$old_library"
> -@@ -3060,14 +3019,14 @@ func_mode_install ()
> +@@ -4388,14 +4347,14 @@ func_mode_install ()
>  
>   # Install the libtool object if requested.
>   test -n "$destfile" && \
> @@ -90,7 +92,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>  +  func_show_eval "$install_prog $extra_mode $file $destfile" 'exit $?'
>  
>   # Install the old object if enabled.
> - if test "$build_old_libs" = yes; then
> + if test yes = "$build_old_libs"; then
>    # Deduce the name of the old-style object file.
>    func_lo2o "$file"
>    staticobj=$func_lo2o_result
> @@ -99,7 +101,7 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>   fi
>   exit $EXIT_SUCCESS
>   ;;
> -@@ -5660,6 +5619,7 @@ func_mode_link ()
> +@@ -7075,6 +7034,7 @@ func_mode_link ()
>   func_append compiler_flags " $arg"
>   func_append compile_command " $arg"
>   func_append finalize_command " $arg"
> @@ -107,27 +109,27 @@ $OpenBSD: patch-libltdl_config_ltmain_sh
>   case "$new_inherited_linker_flags " in
>      *" $arg "*) ;;
>      * ) func_append new_inherited_linker_flags " $arg" ;;
> -@@ -6167,6 +6127,7 @@ func_mode_link ()
> +@@ -7611,6 +7571,7 @@ func_mode_link ()
>      finalize_deplibs="$deplib $finalize_deplibs"
>    else
>      func_append compiler_flags " $deplib"
> -+    test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
> -    if test "$linkmode" = lib ; then
> ++        test "$linkmode" = lib && newdependency_libs="$deplib $newdependency_libs"
> +    if test lib = "$linkmode"; then
>   case "$new_inherited_linker_flags " in
>      *" $deplib "*) ;;
> -@@ -6697,7 +6658,7 @@ func_mode_link ()
> +@@ -8140,7 +8101,7 @@ func_mode_link ()
>    *)
> -    if test "$installed" = no; then
> +    if test no = "$installed"; then
>        func_append notinst_deplibs " $lib"
>  -      need_relink=yes
>  +      test -z "$DESTDIR" && need_relink=yes
>      fi
>      ;;
>    esac
> -@@ -7521,6 +7482,20 @@ func_mode_link ()
> +@@ -9010,6 +8971,20 @@ func_mode_link ()
>    major=
>    versuffix=
> -  verstring=""
> +  verstring=
>  + else
>  +  # XXX
>  +  tmp=`echo $libname|sed -e 's,+,_,g' -e 's,-,_,g' -e 's,\.,_,g'`
> Index: pkg/PLIST-ltdl
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/pkg/PLIST-ltdl,v
> retrieving revision 1.5
> diff -u -p -r1.5 PLIST-ltdl
> --- pkg/PLIST-ltdl 19 Mar 2015 20:25:26 -0000 1.5
> +++ pkg/PLIST-ltdl 23 Feb 2021 15:22:13 -0000
> @@ -4,47 +4,43 @@ include/libltdl/lt_dlloader.h
>  include/libltdl/lt_error.h
>  include/libltdl/lt_system.h
>  include/ltdl.h
> -lib/libltdl.a
> +@static-lib lib/libltdl.a
>  lib/libltdl.la
>  @lib lib/libltdl.so.${LIBltdl_VERSION}
>  share/aclocal/
>  share/aclocal/ltdl.m4
>  share/libtool/
> +share/libtool/COPYING.LIB
> +share/libtool/Makefile.am
> +share/libtool/Makefile.in
> +share/libtool/README
> +share/libtool/aclocal.m4
> +share/libtool/config-h.in
> +share/libtool/configure
> +share/libtool/configure.ac
>  share/libtool/libltdl/
> -share/libtool/libltdl/COPYING.LIB
> -share/libtool/libltdl/Makefile.am
> -share/libtool/libltdl/Makefile.in
> -share/libtool/libltdl/Makefile.inc
> -share/libtool/libltdl/README
> -share/libtool/libltdl/aclocal.m4
> -share/libtool/libltdl/argz.c
> -share/libtool/libltdl/argz_.h
> -share/libtool/libltdl/config-h.in
> -share/libtool/libltdl/configure
> -share/libtool/libltdl/configure.ac
> -share/libtool/libltdl/libltdl/
> -share/libtool/libltdl/libltdl/lt__alloc.h
> -share/libtool/libltdl/libltdl/lt__dirent.h
> -share/libtool/libltdl/libltdl/lt__glibc.h
> -share/libtool/libltdl/libltdl/lt__private.h
> -share/libtool/libltdl/libltdl/lt__strl.h
> -share/libtool/libltdl/libltdl/lt_dlloader.h
> -share/libtool/libltdl/libltdl/lt_error.h
> -share/libtool/libltdl/libltdl/lt_system.h
> -share/libtool/libltdl/libltdl/slist.h
> -share/libtool/libltdl/loaders/
> -share/libtool/libltdl/loaders/dld_link.c
> -share/libtool/libltdl/loaders/dlopen.c
> -share/libtool/libltdl/loaders/dyld.c
> -share/libtool/libltdl/loaders/load_add_on.c
> -share/libtool/libltdl/loaders/loadlibrary.c
> -share/libtool/libltdl/loaders/preopen.c
> -share/libtool/libltdl/loaders/shl_load.c
> -share/libtool/libltdl/lt__alloc.c
> -share/libtool/libltdl/lt__dirent.c
> -share/libtool/libltdl/lt__strl.c
> -share/libtool/libltdl/lt_dlloader.c
> -share/libtool/libltdl/lt_error.c
> -share/libtool/libltdl/ltdl.c
> -share/libtool/libltdl/ltdl.h
> -share/libtool/libltdl/slist.c
> +share/libtool/libltdl/lt__alloc.h
> +share/libtool/libltdl/lt__dirent.h
> +share/libtool/libltdl/lt__glibc.h
> +share/libtool/libltdl/lt__private.h
> +share/libtool/libltdl/lt__strl.h
> +share/libtool/libltdl/lt_dlloader.h
> +share/libtool/libltdl/lt_error.h
> +share/libtool/libltdl/lt_system.h
> +share/libtool/libltdl/slist.h
> +share/libtool/loaders/
> +share/libtool/loaders/dld_link.c
> +share/libtool/loaders/dlopen.c
> +share/libtool/loaders/dyld.c
> +share/libtool/loaders/load_add_on.c
> +share/libtool/loaders/loadlibrary.c
> +share/libtool/loaders/preopen.c
> +share/libtool/loaders/shl_load.c
> +share/libtool/lt__alloc.c
> +share/libtool/lt__dirent.c
> +share/libtool/lt__strl.c
> +share/libtool/lt_dlloader.c
> +share/libtool/lt_error.c
> +share/libtool/ltdl.c
> +share/libtool/ltdl.h
> +share/libtool/slist.c
> Index: pkg/PLIST-main
> ===================================================================
> RCS file: /cvs/ports/devel/libtool/pkg/PLIST-main,v
> retrieving revision 1.2
> diff -u -p -r1.2 PLIST-main
> --- pkg/PLIST-main 22 Sep 2011 21:10:19 -0000 1.2
> +++ pkg/PLIST-main 23 Feb 2021 15:22:13 -0000
> @@ -5,17 +5,20 @@ bin/libtoolize
>  @info info/libtool.info
>  @man man/man1/libtool.1
>  @man man/man1/libtoolize.1
> -share/aclocal/argz.m4
>  share/aclocal/libtool.m4
> +share/aclocal/ltargz.m4
>  share/aclocal/ltoptions.m4
>  share/aclocal/ltsugar.m4
>  share/aclocal/ltversion.m4
>  share/aclocal/lt~obsolete.m4
> -share/libtool/config/
> -share/libtool/config/compile
> -share/libtool/config/config.guess
> -share/libtool/config/config.sub
> -share/libtool/config/depcomp
> -share/libtool/config/install-sh
> -share/libtool/config/ltmain.sh
> -share/libtool/config/missing
> +share/libtool/build-aux/
> +share/libtool/build-aux/compile
> +share/libtool/build-aux/config.guess
> +share/libtool/build-aux/config.sub
> +share/libtool/build-aux/depcomp
> +share/libtool/build-aux/install-sh
> +share/libtool/build-aux/ltmain.sh
> +share/libtool/build-aux/missing
> +share/libtool/libltdl/lt__argz_.h
> +share/libtool/lt__argz.c
> +share/libtool/ltdl.mk
>

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Stuart Henderson
On 2021/02/23 21:33, Stuart Henderson wrote:
> On 2021/02/23 15:25, Stuart Henderson wrote:
> > I'll do some testing, I'm using this updated diff
>
> Oh yuk, gnu m4 is now needed at runtime for libtoolize.
> Is there a way around that?

Also requires help2man as a BUILD_DEPENDS (but that's not so bad).

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
In reply to this post by Stuart Henderson

Stuart Henderson <[hidden email]> writes:

> On 2021/02/23 15:25, Stuart Henderson wrote:
>> I'll do some testing, I'm using this updated diff
>
> Oh yuk, gnu m4 is now needed at runtime for libtoolize.
> Is there a way around that?

This is probably from

  - GNU M4 is required to run libtoolize in a directory with a
    'configure.ac' (or 'configure.in') that needs tracing to determine
    what modes and directories have been specified.

But unfortunately I have no idea how to avoid it, sorry. Maybe
libtoolize could be on its own sub package and only that depends on m4?

Cheers,
Rafael

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Stuart Henderson
On 2021/02/23 17:17, Rafael Ávila de Espíndola wrote:

>
> Stuart Henderson <[hidden email]> writes:
>
> > On 2021/02/23 15:25, Stuart Henderson wrote:
> >> I'll do some testing, I'm using this updated diff
> >
> > Oh yuk, gnu m4 is now needed at runtime for libtoolize.
> > Is there a way around that?
>
> This is probably from
>
>   - GNU M4 is required to run libtoolize in a directory with a
>     'configure.ac' (or 'configure.in') that needs tracing to determine
>     what modes and directories have been specified.
>
> But unfortunately I have no idea how to avoid it, sorry. Maybe
> libtoolize could be on its own sub package and only that depends on m4?

A subpackage for libtoolize makes no sense. libtoolize and the libtool.m4
files are literally all that are used by most ports using devel/libtool.
Perhaps it can be persuaded to run with /usr/bin/m4 though, it depends
what it wants from gm4.

Another problem showed up in the build,

-----
configure.in:16: error: Autoconf version 2.62 or higher is required
 
/usr/local/share/aclocal/libtool.m4:96: LT_INIT is expanded from...
/usr/local/share/aclocal/libtool.m4:100: AM_PROG_LIBTOOL is expanded from...
 
configure.in:16: the top level
 
autom4te-2.61: /usr/bin/m4 failed with exit status: 63
aclocal-1.9: autom4te failed with exit status: 63
-----

With this update everything that uses both devel/libtool and autoconf
needs to use autoconf >= 2.62.

$ grep devel/libtool /usr/local/share/ports-INDEX | grep autoconf | grep -v 'autoconf/2\.6[2-9]' | cut -d'|' -f2
audio/faad
audio/fluidsynth
audio/mp3blaster
audio/swh-plugins
audio/timidity
audio/timidity,gtk2
audio/timidity,xaw
devel/ois
emulators/x48
games/numptyphysics
games/numptyphysics,-npcomplete
games/zangband
games/zangband,no_x11
graphics/agg
graphics/geeqie
misc/hfsplus
net/ices2
sysutils/colortail
sysutils/inotify-tools

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Rafael Ávila de Espíndola
Stuart Henderson <[hidden email]> writes:

> On 2021/02/23 17:17, Rafael Ávila de Espíndola wrote:
>>
>> Stuart Henderson <[hidden email]> writes:
>>
>> > On 2021/02/23 15:25, Stuart Henderson wrote:
>> >> I'll do some testing, I'm using this updated diff
>> >
>> > Oh yuk, gnu m4 is now needed at runtime for libtoolize.
>> > Is there a way around that?
>>
>> This is probably from
>>
>>   - GNU M4 is required to run libtoolize in a directory with a
>>     'configure.ac' (or 'configure.in') that needs tracing to determine
>>     what modes and directories have been specified.
>>
>> But unfortunately I have no idea how to avoid it, sorry. Maybe
>> libtoolize could be on its own sub package and only that depends on m4?
>
> A subpackage for libtoolize makes no sense. libtoolize and the libtool.m4
> files are literally all that are used by most ports using devel/libtool.
> Perhaps it can be persuaded to run with /usr/bin/m4 though, it depends
> what it wants from gm4.

Scrap that then. It is the first time I hear about libtoolize and the
manual page made me think it was something that was run once when
starting a project that uses libtool:

DESCRIPTION
       Prepare a package to use libtool.

> Another problem showed up in the build,
>
> -----
> configure.in:16: error: Autoconf version 2.62 or higher is required
>  
> /usr/local/share/aclocal/libtool.m4:96: LT_INIT is expanded from...
> /usr/local/share/aclocal/libtool.m4:100: AM_PROG_LIBTOOL is expanded from...
>  
> configure.in:16: the top level
>  
> autom4te-2.61: /usr/bin/m4 failed with exit status: 63
> aclocal-1.9: autom4te failed with exit status: 63
> -----
>
> With this update everything that uses both devel/libtool and autoconf
> needs to use autoconf >= 2.62.
>
> $ grep devel/libtool /usr/local/share/ports-INDEX | grep autoconf | grep -v 'autoconf/2\.6[2-9]' | cut -d'|' -f2

Interesting, so a project can depend on the gnu libtool both by depending
on devel/libtool or adding "USE_LIBTOOL = gnu"? I missed the first ones :-(

> audio/faad
> audio/fluidsynth
> audio/mp3blaster
> audio/swh-plugins
> audio/timidity
> audio/timidity,gtk2
> audio/timidity,xaw
> devel/ois
> emulators/x48
> games/numptyphysics
> games/numptyphysics,-npcomplete
> games/zangband
> games/zangband,no_x11
> graphics/agg
> graphics/geeqie
> misc/hfsplus
> net/ices2
> sysutils/colortail
> sysutils/inotify-tools

And given that it is better to just use the autoconf upstream uses, this
basically means waiting for these packages to change. Any idea how linux
distros handle this? I see, for example, that debian has many autoconf
versions, but only one version of libtool.

Cheers,
Rafael

Reply | Threaded
Open this post in threaded view
|

Re: Update libtool

Marc Espie-2
On Wed, Feb 24, 2021 at 08:03:06AM -0800, Rafael Ávila de Espíndola wrote:

> Stuart Henderson <[hidden email]> writes:
>
> > On 2021/02/23 17:17, Rafael Ávila de Espíndola wrote:
> >>
> >> Stuart Henderson <[hidden email]> writes:
> >>
> >> > On 2021/02/23 15:25, Stuart Henderson wrote:
> >> >> I'll do some testing, I'm using this updated diff
> >> >
> >> > Oh yuk, gnu m4 is now needed at runtime for libtoolize.
> >> > Is there a way around that?
> >>
> >> This is probably from
> >>
> >>   - GNU M4 is required to run libtoolize in a directory with a
> >>     'configure.ac' (or 'configure.in') that needs tracing to determine
> >>     what modes and directories have been specified.
> >>
> >> But unfortunately I have no idea how to avoid it, sorry. Maybe
> >> libtoolize could be on its own sub package and only that depends on m4?
> >
> > A subpackage for libtoolize makes no sense. libtoolize and the libtool.m4
> > files are literally all that are used by most ports using devel/libtool.
> > Perhaps it can be persuaded to run with /usr/bin/m4 though, it depends
> > what it wants from gm4.
>
> Scrap that then. It is the first time I hear about libtoolize and the
> manual page made me think it was something that was run once when
> starting a project that uses libtool:
>
> DESCRIPTION
>        Prepare a package to use libtool.

Do not feel bad, most of libtool is a shitshow.

you do think "yeah it's gonna be used that way", and then you go
"oh no they wouldn't"

(yes they will)

you did set foot into a VERY unpalatable place.

Here there might be dragons.

(do not feel bad, though... there are still dragons in newer projects,
they're called meson or cmake instead of autocrap, but they still fail
in hilarious ways)