LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Desktop (http://www.linuxquestions.org/questions/linux-desktop-74/)
-   -   Installing libFOX for XFE (http://www.linuxquestions.org/questions/linux-desktop-74/installing-libfox-for-xfe-544194/)

chaz_bro1972 04-08-2007 01:32 AM

Installing libFOX for XFE
 
Hey there fellow posters:

I'm looking for some assistance getting Fox-1.6 to install and work so I can install XFE (X File Explorer). I'm using Slackware 11, in case you needed to know that. I'm installing from the source tarballs:
I installed Fox-1.6 already once (or so I thought). Then when I went to ./configure XFE, it wouldnt configure to allow me to 'make'.

I am a little bit of (keyword here: little) a newbie. I am attempting to get 'Look XP' to work since I'm using and older PC (see signature). I have already installed all the other files that Look XP said to do:
  • imlib & imlib2 (aka imlib-devel)
  • IceWM-1.2.30.LXP.tar.gz
  • lxp-02.tar.gz
  • idesk-0.7.5-LXP.tar.gz

If I need to do something with the $PATH, I need to be told exactly, because I have no knowledge of what the $PATH is or does, or even how to alter it.

Thanks,
Chaz

slakmagik 04-08-2007 03:39 AM

Ironic - I'm going through apps to remove and am about to yank this one - but all I do is (relevant parts from buildscripts):

fox:
Code:

    ./configure --prefix=/usr/local --disable-nls \
        --with-xft=yes \
        --disable-static \
        --enable-threadsafe
    make
    make DESTDIR=$PKGDIR install

xfe
Code:

    ./configure --prefix=/usr/local --disable-nls \
        --mandir=/usr/local/man
    make
    make DESTDIR=$PKGDIR install

Other than busted xft on an much older fox/xfe, I've never had any trouble with them. Might want to expand on the "wouldn't allow" part and post exact errors.

slakmagik 04-08-2007 03:43 AM

Quote:

Originally Posted by chaz_bro1972
If I need to do something with the $PATH, I need to be told exactly, because I have no knowledge of what the $PATH is or does, or even how to alter it.

Thanks,
Chaz

Just caught this part - the path is the set of directories the shell searches to find executables and the way to alter it is to assign a value to the variable, like

PATH=$PATH:/my/new/path

That assigns the old value and an appended directory to the variable. To make such changes permanent, put them in your shell configuration files - .bashrc/.bash_profile/etc for bash.

chaz_bro1972 04-09-2007 09:31 PM

Results of XFE's attempt to configure...
 
Remember this is after Fox-1.6 is already installed:
Code:

root@cs:/opt/lookxp/xfe-0.99# ./configure
checking for a BSD-compatible install... /usr/bin/ginstall -c
checking whether build environment is sane... yes
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make sets $(MAKE)... (cached) yes
checking for gcc... gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for a BSD-compatible install... /usr/bin/ginstall -c
checking for special C compiler options needed for large files... no
checking for _FILE_OFFSET_BITS value needed for large files... 64
checking whether NLS is requested... yes
checking for msgfmt... /usr/bin/msgfmt
checking for gmsgfmt... /usr/bin/msgfmt
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking build system type... i586-pc-linux-gnu
checking host system type... i586-pc-linux-gnu
checking how to run the C preprocessor... gcc -E
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking whether we are using the GNU C Library 2 or newer... yes
checking for ranlib... ranlib
checking for simple visibility declarations... no
checking for inline... inline
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for size_t... yes
checking for stdint.h... yes
checking for working alloca.h... yes
checking for alloca... yes
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for getpagesize... yes
checking for working mmap... yes
checking whether integer division by zero raises SIGFPE... yes
checking for inttypes.h... yes
checking for unsigned long long int... yes
checking for inttypes.h... (cached) yes
checking whether the inttypes.h PRIxNN macros are broken... no
checking for ld used by GCC... /usr/i486-slackware-linux/bin/ld
checking if the linker (/usr/i486-slackware-linux/bin/ld) is GNU ld... yes
checking for shared library run path origin... done
checking whether imported symbols can be declared weak... yes
checking pthread.h usability... yes
checking pthread.h presence... yes
checking for pthread.h... yes
checking for pthread_kill in -lpthread... yes
checking for pthread_rwlock_t... yes
checking for multithread API to use... posix
checking argz.h usability... yes
checking argz.h presence... yes
checking for argz.h... yes
checking for inttypes.h... (cached) yes
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking for unistd.h... (cached) yes
checking sys/param.h usability... yes
checking sys/param.h presence... yes
checking for sys/param.h... yes
checking for getcwd... yes
checking for getegid... yes
checking for geteuid... yes
checking for getgid... yes
checking for getuid... yes
checking for mempcpy... yes
checking for munmap... yes
checking for stpcpy... yes
checking for strcasecmp... yes
checking for strdup... yes
checking for strtoul... yes
checking for tsearch... yes
checking for argz_count... yes
checking for argz_stringify... yes
checking for argz_next... yes
checking for __fsetlocking... yes
checking whether feof_unlocked is declared... yes
checking whether fgets_unlocked is declared... yes
checking for iconv... yes
checking for iconv declaration...
        extern size_t iconv (iconv_t cd, char * *inbuf, size_t *inbytesleft, char * *outbuf, size_t *outbytesleft);
checking for NL_LOCALE_NAME macro... no
checking for bison... bison
checking version of bison... 2.1, ok
checking for long long int... yes
checking for long double... yes
checking for wchar_t... yes
checking for wint_t... yes
checking for intmax_t... yes
checking whether printf() supports POSIX/XSI format strings... yes
checking whether we are using the GNU C Library 2.1 or newer... yes
checking for stdint.h... (cached) yes
checking for SIZE_MAX... yes
checking for stdint.h... (cached) yes
checking for CFPreferencesCopyAppValue... no
checking for CFLocaleCopyCurrent... no
checking for ptrdiff_t... yes
checking stddef.h usability... yes
checking stddef.h presence... yes
checking for stddef.h... yes
checking for stdlib.h... (cached) yes
checking for string.h... (cached) yes
checking for asprintf... yes
checking for fwprintf... yes
checking for putenv... yes
checking for setenv... yes
checking for setlocale... yes
checking for snprintf... yes
checking for wcslen... yes
checking whether _snprintf is declared... no
checking whether _snwprintf is declared... no
checking whether getc_unlocked is declared... yes
checking for nl_langinfo and CODESET... yes
checking for LC_MESSAGES... yes
checking for CFPreferencesCopyAppValue... (cached) no
checking for CFLocaleCopyCurrent... (cached) no
checking whether included gettext is requested... no
checking for GNU gettext in libc... yes
checking whether to use NLS... yes
checking where the gettext function comes from... libc
checking for fxfindfox in -lFOX-1.6... no
configure: error: "libFOX-1.6 not found"
root@cs:/opt/lookxp/xfe-0.99#

Does this help? Need more? Just say so.
BTW, Thanks for explaining $PATH. Why would I need to adjust $PATH for applications?

slakmagik 04-10-2007 12:48 AM

As far as changing the path, say you install a program to your home directory - $HOME/bin isn't on your path, so you add it. Or something like TeX, which keeps binaries in its own hierarchy, will need to be on the path.

As far as your compile error, xfe is simply not finding fox. This is likely because something went badly wrong with the install and it didn't get properly installed at all, or because you've installed it some place strange. You seem to be building in /opt/lookxp/xfe-0.99, which is kinda weird itself. If fox is somewhere in /opt you'll need to add that directory to /etc/ld.so.conf and do an 'ldconfig'. (You could also just point to it with LDFLAGS.)

If none of that is it, I probably can't help but you could post exactly what your build process was for fox and whether you have a /var/log/packages entry (if you packaged it) or at least whether the stuff made it onto the system at all. If you just built it with './configure' like you're showing for xfe, itself, then I have no idea what's wrong, because that should install to /usr/local by default and xfe should just pick it up. I suppose your ld.so.conf could be messed up - make sure that has /usr/local/lib in it.

Anyway - all this is to do with another sort of path - library paths. :)

chaz_bro1972 04-10-2007 09:37 PM

Ok, when i installed fox, there were warnings, but it kept going. it did install. so maybe its the fact its in the /opt directory. I am new to things... and i do get things wrong. where am i to download files... then install them from - be explicit please.

How do i 'point to it with LDFLAGS'? Packaged it (dont know what u mean)? I just do the normal steps for source code install:
1) # tar zxvf (or jxvf) <file>.tar.gz (or tar.bz2)
2) # cd ./<directory>
3) <read INSTALL &/or README>
4) # ./configure --help
5) # ./configure <whatever it needs>
6) # make
7) # make install

should i (when installing fox)?:

# ./configure --prefix=/usr --exec-prefix=/usr

Are you telling me there is 2 different kinds of paths? now i am really confused. Thanks... thanks a lot.

slakmagik 04-11-2007 05:41 PM

Sorry - I seem to have a knack for confusing people. ;) I think I'm going to quit posting here again because of that - my fault; not yours.

Quote:

Originally Posted by chaz_bro1972
Ok, when i installed fox, there were warnings, but it kept going.

Warnings are usually just that - warnings. So that's probably nothing to worry about.

Quote:

it did install. so maybe its the fact its in the /opt directory. I am new to things... and i do get things wrong. where am i to download files... then install them from - be explicit please.
Everybody gets things wrong - even the kernel devs have had a few 'brown paper bag' releases (means very embarrassing goofs). Okay - there are two things to distinguish here: (1) where you are installing *from* and where the source code *is*, (2) where you are installing *to* and where the binaries produced from the source *will go*. So the fact that you have the source code in /opt and are installing from there is not a problem at all. Just unusual, so I was wondering if you were also installing *to* /opt. In that case, as I said, you'd need to add that library path to ld.so.conf.

Quote:

How do i 'point to it with LDFLAGS'?
As an example, 'LDFLAGS=-L/opt/lib ./configure && make && make install', I believe. Basically, this is putting something into the environment by assigning a value to a variable which the toolchain used to build packages will look for and modify their behavior accordingly.

Quote:

Packaged it (dont know what u mean)? I just do the normal steps for source code install:
1) # tar zxvf (or jxvf) <file>.tar.gz (or tar.bz2)
2) # cd ./<directory>
3) <read INSTALL &/or README>
4) # ./configure --help
5) # ./configure <whatever it needs>
6) # make
7) # make install
Well, Slackware is composed of *tgz packages, such as bash-3.2.015-i486-1 and these are built by creating a buildscript which basically does the steps you outline above and then calls the 'makepkg' script (which is part of the pkgtools package). This makes it easy to add, remove, rebuild, etc., programs. Some people build their own packages just like that (myself included) and some use various third party tools like checkinstall that do somewhat similar things.

Incidentally, tar versions >= 1.15 don't require the z or j flags (though it certainly doesn't hurt and is good for backware compatibility) so if you don't need them, you can skip them. I also don't have much use for the verbose flag except in specific cases. Steps 3 & 4 you describe are very important - many people skip those. :)

Quote:

should i (when installing fox)?:

# ./configure --prefix=/usr --exec-prefix=/usr
You could - as I say, if you do './configure' that should be exactly the same as doing './configure --prefix=/usr/local'. Both xfe and fox should do this and so xfe should have no trouble finding the fox library and building. But stock Slackware packages (and most 3rd party packages) are built with './configure --prefix=/usr'. This should also work, but shouldn't work any 'better' than /usr/local. So, as I say, I was reduced to wondering if fox had installed at all, or if what you had actually issued was something like './configure --prefix=/opt'. If you had done that, xfe would not be likely to find fox.

Quote:

Are you telling me there is 2 different kinds of paths? now i am really confused. Thanks... thanks a lot.
Well, if it's confusing, ignore it for now, but there are all kinds of paths - for instance, I get:

Code:

:set | awk -F= '/PATH/{ print $1 }'
CHOICESPATH
MANPATH
PATH
PKG_CONFIG_PATH
        manpath

The first is cruft from a file manager I set to /dev/null (it now uses XDG stuff) and the second is where the 'man' command looks for documentation, the third is where binaries/scripts are looked for, and the fourth is where the *pc files live, which are used to pass some of the library/include values we've been talking about. But when people say plain 'path' they generally mean the search path for executable binaries and scripts. Like I say, if this helps great and, if not, ignore it. :)

Anyway - if you didn't pass an argument of something like '--prefix=/opt' to configure, and 'ls /usr/local/lib/libFOX*' returns a few files, I have no idea what's wrong, because xfe should find that. If not, do either an 'updatedb' and the 'locate libFOX' or do a 'find / -name '*libFOX*''. (This is another reason for building packages - you can see where stuff is going before you install it and if you forget and need to find out again later, you can just grep /var/log/packages.) And if you don't find it, fox didn't install after all and, if you find it somewhere weird, take one or more of the steps we've mentioned to fix it.

And as far as generalized troubleshooting, always pay careful attention to error messages, paste them into a search engine if needed, check the relevant man pages if you know which ones, or try 'man -k' if you don't.

Hope something in here helps. :)


All times are GMT -5. The time now is 11:34 PM.