Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Rich Shepard

On Mon, 21 Jun 2021, Robert Citek wrote:


For my own curiosity, how did you install perl-Gtk3? I know you found it
on SBo, but not being familiar enough with Slack, I am curious to know
what commands you used to install it ( as well as its six dependencies. )


Robert,

I used the SBo build script: perl-Gtk3.SlackBuild
--8<---
#!/bin/sh

# Slackware build script for perl-Gtk3

# Copyright 2019 M.A.Begue mab...@gmail.com
# All rights reserved.
#
# Redistribution and use of this script, with or without modification, is
# permitted provided that the following conditions are met:
#
# 1. Redistributions of this script must retain the above copyright
#notice, this list of conditions and the following disclaimer.
#
#  THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
#  WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
#  MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.  IN NO
#  EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
#  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
#  PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
#  OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
#  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
#  OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
#  ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

PRGNAM=perl-Gtk3
VERSION=${VERSION:-0.038}
BUILD=${BUILD:-1}
TAG=${TAG:-_SBo}

SRCNAM="$(printf $PRGNAM | cut -d- -f2-)"

if [ -z "$ARCH" ]; then
  case "$( uname -m )" in
i?86) ARCH=i586 ;;
arm*) ARCH=arm ;;
   *) ARCH=$( uname -m ) ;;
  esac
fi

CWD=$(pwd)
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}

if [ "$ARCH" = "i586" ]; then
  SLKCFLAGS="-O2 -march=i586 -mtune=i686"
  LIBDIRSUFFIX=""
elif [ "$ARCH" = "i686" ]; then
  SLKCFLAGS="-O2 -march=i686 -mtune=i686"
  LIBDIRSUFFIX=""
elif [ "$ARCH" = "x86_64" ]; then
  SLKCFLAGS="-O2 -fPIC"
  LIBDIRSUFFIX="64"
else
  SLKCFLAGS="-O2"
  LIBDIRSUFFIX=""
fi

set -e

rm -rf $PKG
mkdir -p $TMP $PKG $OUTPUT
cd $TMP
rm -rf $SRCNAM-$VERSION
tar xvf $CWD/$SRCNAM-$VERSION.tar.gz
cd $SRCNAM-$VERSION
chown -R root:root .
find -L . \
 \( -perm 777 -o -perm 775 -o -perm 750 -o -perm 711 -o -perm 555 \
  -o -perm 511 \) -exec chmod 755 {} \; -o \
 \( -perm 666 -o -perm 664 -o -perm 640 -o -perm 600 -o -perm 444 \
  -o -perm 440 -o -perm 400 \) -exec chmod 644 {} \;

perl Makefile.PL \
  PREFIX=/usr \
  INSTALLDIRS=vendor \
  INSTALLVENDORMAN1DIR=/usr/man/man1 \
  INSTALLVENDORMAN3DIR=/usr/man/man3
make
make install DESTDIR=$PKG

find $PKG -print0 | xargs -0 file | grep -e "executable" -e "shared object" | 
grep ELF \
  | cut -f 1 -d : | xargs strip --strip-unneeded 2> /dev/null || true

find $PKG/usr/man -type f -exec gzip -9 {} \;
for i in $( find $PKG/usr/man -type l ) ; do ln -s $( readlink $i ).gz $i.gz ; 
rm $i ; done

find $PKG -name perllocal.pod -o -name ".packlist" -o -name "*.bs" | xargs rm 
-f || true

find $PKG -depth -type d -empty -delete || true

mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a \
  NEWS README \
  $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild

mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc

cd $PKG
/sbin/makepkg -l y -c n 
$OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
-->8

Rich


Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Robert Citek
On Mon, Jun 21, 2021 at 8:28 AM, Rich Shepard 
wrote:

> I found perl-Gtk3 on SBo (SlackBuilds.org) and installed it and its 6
> dependencies.
>
> Now CGStar builds but displays a long list of optional dependencies it
> cannot find; some actually are installed. I'll run the application without
> the ones not installed here and see if I need them.
>
> Thanks for your time and effort on this issue.
>
> Regards,
>
> Rich


Glad to hear things are working for you.

For my own curiosity, how did you install perl-Gtk3?  I know you found it on
SBo, but not being familiar enough with Slack, I am curious to know what
commands you used to install it ( as well as its six dependencies. )

Thanks in advance.

Regards,
- Robert


Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Rich Shepard

On Mon, 21 Jun 2021, Ken Stephens wrote:


I wonder if you use the pip module to install gtk3?


Ken,

GTK+3 is installed via SBo, the Slackware non-core package repository.


python3 -m pip install gtk3


GTK+3 is not a python package ...


or is the CPAN module the pip module?\


... and CPAN is the Comprehensive Perl Archive Network. Two different
scripting tools.

The SBo repo provides perl-gtk3.

Now all's well.

Keep polishing your chromebook and stay well,

Rich


Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Ken Stephens
Rich,

I wonder if you use the pip module to install gtk3?

python3 -m pip install gtk3

or is the CPAN module the pip module?\

Ken, sitting at a chromebook with servers resting for the night.



On Mon, Jun 21, 2021 at 7:28 AM Rich Shepard 
wrote:

> On Mon, 21 Jun 2021, Robert Citek wrote:
>
> > Good luck and let us know how things go.
>
> Robert,
>
> I found perl-Gtk3 on SBo (SlackBuilds.org) and installed it and its 6
> dependencies.
>
> Now CGStar builds but displays a long list of optional dependencies it
> cannot find; some actually are installed. I'll run the application without
> the ones not installed here and see if I need them.
>
> Thanks for your time and effort on this issue.
>
> Regards,
>
> Rich
>
>


Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Rich Shepard

On Mon, 21 Jun 2021, Robert Citek wrote:


Good luck and let us know how things go.


Robert,

I found perl-Gtk3 on SBo (SlackBuilds.org) and installed it and its 6
dependencies.

Now CGStar builds but displays a long list of optional dependencies it
cannot find; some actually are installed. I'll run the application without
the ones not installed here and see if I need them.

Thanks for your time and effort on this issue.

Regards,

Rich



Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Robert Citek
On Mon, Jun 21, 2021 at 6:44 AM Rich Shepard 
wrote:

> On Sun, 20 Jun 2021, Robert Citek wrote:
>
> > Can you please provide some context info, such as, what OS, what distro,
> > what version, what commands?
>
> Robert,
>
> Slackware-14.2/x86_65, perl-5.22.2-x86_64-1.
>
> Two installation approaches:
>
> # perl -MCPAN -e shell
> cpan[1]> install Gtk3.pm
> ...
> Files=22, Tests=0,  1 wallclock secs ( 0.05 usr  0.02 sys +  1.02 cusr
> 0.13 csys =  1.22 CPU)
> Result: FAIL
> Failed 22/22 test programs. 0/0 subtests failed.
> Makefile:851: recipe for target 'test_dynamic' failed
> make: *** [test_dynamic] Error 2
>XAOC/Gtk3-0.038.tar.gz
>/usr/bin/make test -- NOT OK
> //hint// to see the cpan-testers results for installing this module, try:
>reports XAOC/Gtk3-0.038.tar.gz
> Failed during this command:
>   XAOC/Gtk3-0.038.tar.gz   : make_test NO
>
> # cpan[2] install Gtk3.pm
> ...
> Files=22, Tests=0,  1 wallclock secs ( 0.05 usr  0.02 sys +  1.02 cusr
> 0.13 csys =  1.22 CPU)
> Result: FAIL
> Failed 22/22 test programs. 0/0 subtests failed.
> Makefile:851: recipe for target 'test_dynamic' failed
> make: *** [test_dynamic] Error 2
>XAOC/Gtk3-0.038.tar.gz
>/usr/bin/make test -- NOT OK
> //hint// to see the cpan-testers results for installing this module, try:
>reports XAOC/Gtk3-0.038.tar.gz
> Failed during this command:
>   XAOC/Gtk3-0.038.tar.gz   : make_test NO
>
> I've not before failed to install a perl module using the first approach;
> tried the second approach only today.
>
> Regards,
>
> Rich
>

Hello Rich,

Since I don't usually run Slackware, I used a Docker container to simulate
your environment.
These are the commands I ran:

# download and run a slackware container
  docker run -d --name slack vbatts/slackware:14.2 sleep inf

# install perl
  docker exec slack wget --no-check-certificate
https://slackware.uk/slackware/slackware64-14.2/slackware64/d/perl-5.22.2-x86_64-1.txz
  docker exec slack upgradepkg --install-new perl-5.22.2-x86_64-1.txz
  docker exec slack perl -V

...
  @INC:
/usr/local/lib64/perl5
/usr/local/share/perl5
/usr/lib64/perl5/vendor_perl
/usr/share/perl5/vendor_perl
/usr/lib64/perl5
/usr/share/perl5
.
# install Gtk3.pm
  docker exec slack cpan install Gtk3.pm

  ...
  Running make for X/XA/XAOC/Gtk3-0.038.tar.gz
  Warning: Prerequisite 'Cairo::GObject => 1.000' for
'XAOC/Gtk3-0.038.tar.gz' failed when processing
'XAOC/Cairo-GObject-1.005.tar.gz' with 'writemakefile => NO
'/usr/bin/perl5.22.2 Makefile.PL' returned status 512'. Continuing, but
chances to succeed are limited.
  Warning: Prerequisite 'Glib::Object::Introspection => 0.043' for
'XAOC/Gtk3-0.038.tar.gz' failed when processing
'XAOC/Glib-Object-Introspection-0.049.tar.gz' with 'writemakefile => NO --
No 'Makefile' created
  '. Continuing, but chances to succeed are limited.
XAOC/Gtk3-0.038.tar.gz
make -- NOT OK

Looks like Gtk3 requires other dependencies: Cairo-GObject and
Glib-Object-Introspection.

At this point, I gave up because 1) there are dependency issues which
aren't automatically resolving and 2) the errors I am getting seem to
differ from yours, suggesting that we don't have the same environment.

So, I cleaned up my container environment:
  docker container stop slack
  docker container rm slack
  docker image rm vbatts/slackware:14.2


For comparison, I tried installing the same module using an Ubuntu
container:

# download and run an Ubuntu container
  docker run -d --name ubuntu ubuntu sleep inf

# install perl with Gtk3 module and test
  docker exec ubuntu apt-get update
  docker exec -e DEBIAN_FRONTEND=noninteractive ubuntu apt-get install -y
libgtk3-perl
  docker exec ubuntu perl -mGtk3 -e 'print "== Hello, world!\n";'
== Hello, world!

# clean up container environment
  docker container stop ubuntu
  docker container rm ubuntu
  docker image rm ubuntu

Using an Ubuntu container, I was able to get the Gtk3 module installed and
verified that it ran.

Good luck and let us know how things go.

Regards,
- Robert


Re: [PLUG] Perl: module fails to install

2021-06-21 Thread Rich Shepard

On Sun, 20 Jun 2021, Robert Citek wrote:


Can you please provide some context info, such as, what OS, what distro,
what version, what commands?


Robert,

Slackware-14.2/x86_65, perl-5.22.2-x86_64-1.

Two installation approaches:

# perl -MCPAN -e shell
cpan[1]> install Gtk3.pm
...
Files=22, Tests=0,  1 wallclock secs ( 0.05 usr  0.02 sys +  1.02 cusr  0.13 
csys =  1.22 CPU)
Result: FAIL
Failed 22/22 test programs. 0/0 subtests failed.
Makefile:851: recipe for target 'test_dynamic' failed
make: *** [test_dynamic] Error 2
  XAOC/Gtk3-0.038.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports XAOC/Gtk3-0.038.tar.gz
Failed during this command:
 XAOC/Gtk3-0.038.tar.gz   : make_test NO

# cpan[2] install Gtk3.pm
...
Files=22, Tests=0,  1 wallclock secs ( 0.05 usr  0.02 sys +  1.02 cusr  0.13 
csys =  1.22 CPU)
Result: FAIL
Failed 22/22 test programs. 0/0 subtests failed.
Makefile:851: recipe for target 'test_dynamic' failed
make: *** [test_dynamic] Error 2
  XAOC/Gtk3-0.038.tar.gz
  /usr/bin/make test -- NOT OK
//hint// to see the cpan-testers results for installing this module, try:
  reports XAOC/Gtk3-0.038.tar.gz
Failed during this command:
 XAOC/Gtk3-0.038.tar.gz   : make_test NO

I've not before failed to install a perl module using the first approach;
tried the second approach only today.

Regards,

Rich



Re: [PLUG] Perl: module fails to install

2021-06-20 Thread Robert Citek
On Sun, Jun 20, 2021 at 5:52 PM, Rich Shepard 
wrote:

> On Sun, 20 Jun 2021, Rich Shepard wrote:
>
> > I'm trying to install Gtk3.pm in perl-5.22.2. gtk+3-3.18.9 is also
> > installed, but perl fails the installation.
>
> The errors for trying to install Gtk3.pm and Gtk3 are the same. The 358
> line
> file can be downloaded here:
> <
> http://www.fileconvoy.com/dfl.php?id=g4e99754f653a6fd510003556780737293dc221d628
> >.
>
> Rich
>
Hello Rich,

Can you please provide some context info, such as, what OS, what distro,
what version, what commands?

Regards,
- Robert


Re: [PLUG] Perl: module fails to install

2021-06-20 Thread Rich Shepard

On Sun, 20 Jun 2021, Rich Shepard wrote:


I'm trying to install Gtk3.pm in perl-5.22.2. gtk+3-3.18.9 is also
installed, but perl fails the installation.


The errors for trying to install Gtk3.pm and Gtk3 are the same. The 358 line
file can be downloaded here:
.

Rich