[MacPorts] #69112: libpaper-utils uses rpath instead of the absolute path and installs a broken paperconf binary

MacPorts noreply at macports.org
Sun Feb 4 08:16:55 UTC 2024


#69112: libpaper-utils uses rpath instead of the absolute path and installs a
broken paperconf binary
-----------------------------+--------------------------
  Reporter:  barracuda156    |      Owner:  barracuda156
      Type:  defect          |     Status:  closed
  Priority:  Normal          |  Milestone:
 Component:  ports           |    Version:  2.8.1
Resolution:  fixed           |   Keywords:
      Port:  libpaper-utils  |
-----------------------------+--------------------------

Comment (by ballapete):

 My `Portfile` from 2024-01-16 has:

 {{{
      43 configure.args  --enable-relocatable \
      44                 --disable-silent-rules
      45
      46 if {${subport} eq ${name}} {
      47     test.run    yes
      48     test.target check
      49
      50     post-destroot {
      51         # Using --enable-relocatable is unfortunately needed for
 the
      52         # tests to work, but we don't actually want to use rpath
 in the
      53         # installed library.
      54         system "install_name_tool -id \
      55                 ${prefix}/lib/libpaper.2.dylib \
      56                 ${destroot}${prefix}/lib/libpaper.2.dylib"
      57         # remove `paper` and `paperconf`
      58         delete "${destroot}${prefix}/bin"
      59         delete "${destroot}${prefix}/share/man/man1"
      60     }
      61 } else {
      62     depends_lib-append  port:libpaper
      63
      64     post-destroot {
      65         # https://trac.macports.org/ticket/69112
      66         foreach bin {paper paperconf} {
      67             system "install_name_tool -change
 @rpath/libpaper.2.dylib \
      68                 ${prefix}/lib/libpaper.2.dylib \
      69                 ${destroot}${prefix}/bin/$bin"
      70         }
      71         # remove library-related files (which are already present)
      72         delete "${destroot}${prefix}/etc"
      73         delete "${destroot}${prefix}/include"
      74         delete "${destroot}${prefix}/lib"
      75         delete "${destroot}${prefix}/share/doc/libpaper"
      76         delete "${destroot}${prefix}/share/man/man5"
      77     }
      78 }
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/69112#comment:5>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list