LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Slackware (https://www.linuxquestions.org/questions/slackware-14/)
-   -   slackware64 13.37 alpine.SlackBuild fails when trying to rebuild package (https://www.linuxquestions.org/questions/slackware-14/slackware64-13-37-alpine-slackbuild-fails-when-trying-to-rebuild-package-905702/)

haxwithaxe 09-29-2011 08:00 PM

slackware64 13.37 alpine.SlackBuild fails when trying to rebuild package
 
I'm trying to recompile alpine with passfile support (--with-passfile) and i can't get it to successfully make. the source package seems to have the libdir variable hard coded at some point to be /usr/lib instead of /usr/lib64.
there is an ominous comment block in the slackbuild:
# This seems to ignore sysconfdir and libdir, so it's pretty useless to try them.
# Brute-force it.
# Eric says: no! Use configure parameters.
#zcat $CWD/alpine.config.h.diff.gz | patch -p1 --verbose || exit 1

which would seem to be helpful but neither the configure options nor the patch help. i spent 2 days trying to find all the places where it could possibly go wrong and failed repeatedly.
any help would be appreciated :)

Daedra 09-29-2011 09:16 PM

We'll according to what you posted the patch itself is commented out so it is not getting applied to the build. Did you uncomment the patch line to enable it? if not then do this...

there is an ominous comment block in the slackbuild:
# This seems to ignore sysconfdir and libdir, so it's pretty useless to try them.
# Brute-force it.
# Eric says: no! Use configure parameters.
#zcat $CWD/alpine.config.h.diff.gz | patch -p1 --verbose || exit 1

Change it to look like this then rerun the build.

there is an ominous comment block in the slackbuild:
# This seems to ignore sysconfdir and libdir, so it's pretty useless to try them.
# Brute-force it.
# Eric says: no! Use configure parameters.
zcat $CWD/alpine.config.h.diff.gz | patch -p1 --verbose || exit 1

andrewthomas 09-29-2011 09:48 PM

I don't see what the problem is.

Did you edit the slackbuild and add

Code:

--with-passfile=FILENAME
                          Password cache file (NOT secure, NOT recommended)

with a valid path for FILENAME?

For example,

Code:

# Configure:
CFLAGS="$SLKCFLAGS" \
./configure \
  --prefix=/usr \
  --mandir=/usr/man \
  --with-ssl-dir=/usr \
  --with-ssl-certs-dir=/etc/ssl/certs \
  --with-c-client-target=slx \
  --with-system-pinerc=/etc/pine.conf \
  --with-system-fixed-pinerc=/etc/pine.conf.fixed \
  --disable-debug \
  --with-debug-level=0 \
  --without-tcl \
  --program-prefix= \
  --program-suffix= \
  --with-passfile=/etc/alpine-passfile.conf \
  --build=$ARCH-slackware-linux

I just did that as a test and the package built fine.

haxwithaxe 09-30-2011 10:17 PM

i had already done all that unfortunately :/
@Daedra: the patch doesn't help.
@andrewthomas: i did edit the slackbuild just as you described.

the steps i took were:
1) edit the slackbuild straight from the source repo to have the "--with-passfile=.pine.pwd" and try building (failed)
2) uncomment the patch and try rebuilding. (failed)
3) adding --libdir=/usr/lib64 to the configure options and trying to rebuild (failed)
4) try to find every instance of "/lib" in the build system and replace it with "/lib64" (several ways including find+sed and manually(bad idea)) and try to rebuild (failed)
5) posted here

andrewthomas 09-30-2011 10:50 PM

What is the full path to the pine.pwd file?

You did not state it in your configuration.

At this point, I don't know what to tell you.

I built this package on both x86 and x86_64 with the --passfile configuration option, and it built properly both times.

dive 09-30-2011 11:21 PM

"--with-passfile=.pine.pwd" is a bit ambiguous. Try /etc/pine.pwd maybe?

haxwithaxe 10-01-2011 12:12 AM

Quote:

Originally Posted by dive (Post 4486906)
"--with-passfile=.pine.pwd" is a bit ambiguous. Try /etc/pine.pwd maybe?

it's dieing during make because it is looking for *some* libraries in "/usr/lib" and "/lib" instead of "/usr/lib64" or "/lib64". i don't think the name i chose (i happened to use what i found in the docs) should be affecting where it looks for libraries.

haxwithaxe 10-01-2011 12:45 AM

here is the entire process i used. i just tried it on my laptop with the exact same results i got on my office desktop. (sorry for the handmade diff :P)
Code:

hax@slacktop:~/alpine-build$ files=`wget -q http://mirrors.dotsrc.org/slackware/slackware64-13.37/source/n/alpine/ -O - | head -n21 | tail -n12 | sed -e 's/<\/a>.*$//' -e 's/^.*>//'`

hax@slacktop:~/alpine-build$ for i in $files ;do wget -q http://mirrors.dotsrc.org/slackware/slackware64-13.37/source/n/alpine/$i ;done

hax@slacktop:~/alpine-build$ chmod a+x alpine.SlackBuild

hax@slacktop:~/alpine-build$ vim alpine.SlackBuild
lines 86-88
line 86 == --program-suffix= \
line 87 ++ --with-passfile=.pine.pwd \
line 88 == --build=$ARCH-slackware-linux
lines 92-94
line 92 == # Eric: says: no! Use configure parameters.
line 93 ++ zcat $CWD/alpine.tech-notes.txt.diff.gz | patch -p1 --verbose || exit 1
line 93 -- #zcat $CWD/alpine.tech-notes.txt.diff.gz | patch -p1 --verbose || exit 1
line 94 == <blank line>

hax@slacktop:~/alpine-build$ sudo ./alpine.SlackBuild
<snip>
make[3]: Entering directory `/tmp/alpine-2.00/pico'
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT attach.o -MD -MP -MF .deps/attach.Tpo -c -o attach.o attach.c
mv -f .deps/attach.Tpo .deps/attach.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT basic.o -MD -MP -MF .deps/basic.Tpo -c -o basic.o basic.c
mv -f .deps/basic.Tpo .deps/basic.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT bind.o -MD -MP -MF .deps/bind.Tpo -c -o bind.o bind.c
mv -f .deps/bind.Tpo .deps/bind.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT browse.o -MD -MP -MF .deps/browse.Tpo -c -o browse.o browse.c
mv -f .deps/browse.Tpo .deps/browse.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT buffer.o -MD -MP -MF .deps/buffer.Tpo -c -o buffer.o buffer.c
mv -f .deps/buffer.Tpo .deps/buffer.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT composer.o -MD -MP -MF .deps/composer.Tpo -c -o composer.o composer.c
mv -f .deps/composer.Tpo .deps/composer.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT display.o -MD -MP -MF .deps/display.Tpo -c -o display.o display.c
mv -f .deps/display.Tpo .deps/display.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT file.o -MD -MP -MF .deps/file.Tpo -c -o file.o file.c
mv -f .deps/file.Tpo .deps/file.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT fileio.o -MD -MP -MF .deps/fileio.Tpo -c -o fileio.o fileio.c
mv -f .deps/fileio.Tpo .deps/fileio.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT line.o -MD -MP -MF .deps/line.Tpo -c -o line.o line.c
mv -f .deps/line.Tpo .deps/line.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT pico.o -MD -MP -MF .deps/pico.Tpo -c -o pico.o pico.c
mv -f .deps/pico.Tpo .deps/pico.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT random.o -MD -MP -MF .deps/random.Tpo -c -o random.o random.c
mv -f .deps/random.Tpo .deps/random.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT region.o -MD -MP -MF .deps/region.Tpo -c -o region.o region.c
mv -f .deps/region.Tpo .deps/region.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT search.o -MD -MP -MF .deps/search.Tpo -c -o search.o search.c
mv -f .deps/search.Tpo .deps/search.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT window.o -MD -MP -MF .deps/window.Tpo -c -o window.o window.c
mv -f .deps/window.Tpo .deps/window.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT word.o -MD -MP -MF .deps/word.Tpo -c -o word.o word.c
mv -f .deps/word.Tpo .deps/word.Po
rm -f libpico.a
/usr/bin/ar cru libpico.a attach.o basic.o bind.o browse.o buffer.o composer.o display.o file.o fileio.o line.o pico.o random.o region.o search.o window.o word.o
ranlib libpico.a
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT main.o -MD -MP -MF .deps/main.Tpo -c -o main.o main.c
mv -f .deps/main.Tpo .deps/main.Po
gcc -std=gnu99 -DHAVE_CONFIG_H  -I../include -I/usr/include  -pthread -O2 -fPIC -MT utf8stub.o -MD -MP -MF .deps/utf8stub.Tpo -c -o utf8stub.o utf8stub.c
mv -f .deps/utf8stub.Tpo .deps/utf8stub.Po
/bin/sh ../libtool --tag=CC  --mode=link gcc -std=gnu99 -pthread -O2 -fPIC  -L/usr/lib  -o pico main.o utf8stub.o ../c-client/utf8.o libpico.a osdep/libpicoosd.a ../pith/osdep/libpithosd.a ../pith/charconv/libpithcc.a  -lldap  -lncurses -llber -lssl
mkdir .libs
gcc -std=gnu99 -pthread -O2 -fPIC -o pico main.o utf8stub.o ../c-client/utf8.o  -L/usr/lib libpico.a osdep/libpicoosd.a ../pith/osdep/libpithosd.a ../pith/charconv/libpithcc.a /usr/lib/libldap.so /usr/lib/libsasl2.so -ldl -lcrypto -lncurses /usr/lib/liblber.so -lresolv -lssl -Wl,--rpath -Wl,/usr/lib -Wl,--rpath -Wl,/usr/lib
/usr/lib/libldap.so: could not read symbols: File in wrong format
collect2: ld returned 1 exit status
make[3]: *** [pico] Error 1
make[3]: Leaving directory `/tmp/alpine-2.00/pico'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/tmp/alpine-2.00/pico'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/tmp/alpine-2.00'
make: *** [all] Error 2


dive 10-01-2011 01:05 AM

Hmm I see the problem. If you can't manually fix that /usr/lib by sedding I don't know what to suggest. For some reason it's either not picking up that you are using x86_64 or something is hardcoded into it.

Daedra 10-01-2011 01:21 AM

Quote:

Originally Posted by haxwithaxe (Post 4486019)
I'm trying to recompile alpine with passfile support (--with-passfile) and i can't get it to successfully make. the source package seems to have the libdir variable hard coded at some point to be /usr/lib instead of /usr/lib64.
there is an ominous comment block in the slackbuild:
# This seems to ignore sysconfdir and libdir, so it's pretty useless to try them.
# Brute-force it.
# Eric says: no! Use configure parameters.
#zcat $CWD/alpine.config.h.diff.gz | patch -p1 --verbose || exit 1

which would seem to be helpful but neither the configure options nor the patch help. i spent 2 days trying to find all the places where it could possibly go wrong and failed repeatedly.
any help would be appreciated :)

Just out of curiosity are you using Alien Bob's Multilib packages.

haxwithaxe 10-01-2011 02:14 AM

Quote:

Originally Posted by Daedra (Post 4486956)
Just out of curiosity are you using Alien Bob's Multilib packages.

yes i'm using his multilib packages.
my next move before my buddy told me to ask for help was to move /usr/lib and put a copy of /usr/lib64 in it's place (it worked once for a similar problem).

andrewthomas 10-01-2011 06:32 AM

Quote:

Originally Posted by haxwithaxe (Post 4486996)
yes i'm using his multilib packages.
my next move before my buddy told me to ask for help was to move /usr/lib and put a copy of /usr/lib64 in it's place (it worked once for a similar problem).

I don't know about that approach.

haxwithaxe 10-01-2011 06:35 AM

Quote:

Originally Posted by andrewthomas (Post 4487104)
I don't know about that approach.

On my Gentoo multilib install all the files are in /usr/lib64 and /usr/lib is a symbolic link to /usr/lib64.

in multilib slackware64 (with alienbob's setup at least) the 32bit libs are in /usr/lib and the 64bit libs are in /usr/lib64.
actually i think it would be a tad smarter to make a pure 64bit slackware vm to use for building things like this :/

andrewthomas 10-01-2011 07:07 AM

Quote:

Originally Posted by haxwithaxe (Post 4487105)
actually i think it would be a tad smarter to make a pure 64bit slackware vm to use for building things like this :/

You are correct.

adamk75 10-01-2011 09:23 AM

You can likely get the build to work by temporarily renaming /usr/lib to /usr/lib32

Adam


All times are GMT -5. The time now is 08:52 PM.