gentoo & v7?

Moderators: Site Moderators, FAHC Science Team

gentoo & v7?

Postby jimerickson » Thu Jan 05, 2012 12:53 am

does anyone have v7 running on gentoo? if so i would be interested in knowing how its done.
jimerickson
 
Posts: 533
Joined: Wed May 28, 2008 12:56 am
Location: ames, iowa

Re: gentoo & v7?

Postby smoking2000 » Thu Jan 05, 2012 9:40 am

I haven't tried it yet, but I assume that you can easily run the FAHClient from the tarball version, FAHControl & FAHViewer will work after their python and X dependencies have been installed.

If you've installed full slackware instead of a subset of the series, you should have all dependencies already. Otherwise install the missing packages with slackpkg.
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby smoking2000 » Thu Jan 05, 2012 7:28 pm

Assuming that you've done a minimal slackware installation, you can start by installing the dependencies for FAHClient. Use `ldd` to check if all libraries are found, and install the ones missing:
Code: Select all
bas@vmware-slackware:~/software/folding-fah7$ ldd FAHClient | grep "not found"
        libGL.so.1 => not found

We're missing libGL.so.1, as expected on a system without X.

Praise "Bob" for the existence of slackpkg, the package management tool of choice for SubGenii and Bobbies alike. :P

It makes it easy to find the packages needed to satisfy the dependencies:
Code: Select all
root@vmware-slackware:~# slackpkg file-search libGL.so.1

Looking for libGL.so.1 in package list. Please wait... DONE

The list below shows the packages that contains "libGL\.so\.1" file.

[uninstalled] - mesa-7.9.2-i486-1

You can search specific packages using "slackpkg search package".


And to install them of course:
Code: Select all
root@vmware-slackware:~# slackpkg install mesa         
Package: mesa-7.9.2-i486-1.txz
                        Downloading http://ftp.gwdg.de/pub/linux/slackware/slackware-13.37/./slackware/x/mesa-7.9.2-i486-1.txz...
--2012-01-05 18:48:17--  http://ftp.gwdg.de/pub/linux/slackware/slackware-13.37/slackware/x/mesa-7.9.2-i486-1.txz
Resolving ftp.gwdg.de (ftp.gwdg.de)... 134.76.12.3
Connecting to ftp.gwdg.de (ftp.gwdg.de)|134.76.12.3|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 5183464 (4.9M) [text/plain]
Saving to: "/var/cache/packages/./slackware/x/mesa-7.9.2-i486-1.txz"

100%[====================================================================================================================================================================================================================================>] 5,183,464   1.17M/s   in 4.4s

2012-01-05 18:48:22 (1.12 MB/s) - "/var/cache/packages/./slackware/x/mesa-7.9.2-i486-1.txz" saved [5183464/5183464]

                        Downloading http://ftp.gwdg.de/pub/linux/slackware/slackware-13.37/./slackware/x/mesa-7.9.2-i486-1.txz.asc...
--2012-01-05 18:48:22--  http://ftp.gwdg.de/pub/linux/slackware/slackware-13.37/slackware/x/mesa-7.9.2-i486-1.txz.asc
Resolving ftp.gwdg.de (ftp.gwdg.de)... 134.76.12.3
Connecting to ftp.gwdg.de (ftp.gwdg.de)|134.76.12.3|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 198 [text/plain]
Saving to: "/var/cache/packages/./slackware/x/mesa-7.9.2-i486-1.txz.asc"

100%[====================================================================================================================================================================================================================================>] 198         --.-K/s   in 0s

2012-01-05 18:48:22 (28.7 MB/s) - "/var/cache/packages/./slackware/x/mesa-7.9.2-i486-1.txz.asc" saved [198/198]

        Installing mesa-7.9.2-i486-1...
Verifying package mesa-7.9.2-i486-1.txz.
Installing package mesa-7.9.2-i486-1.txz:
PACKAGE DESCRIPTION:
# mesa (a 3-D graphics library)
#
# Mesa is a 3-D graphics library with an API very similar to that of
# another well-known 3-D graphics library.  :-)  The Mesa libraries are
# used by X to provide both software and hardware accelerated graphics.
#
# Mesa was written by Brian Paul.
#
Executing install script for mesa-7.9.2-i486-1.txz.
Package mesa-7.9.2-i486-1.txz installed.


Searching for NEW configuration files
                No .new files found.


Now we can check FAHClient again to see if we've got all dependencies already:
Code: Select all
bas@vmware-slackware:~/software/folding-fah7$ ldd FAHClient | grep "not found"
        libXxf86vm.so.1 => not found
        libdrm.so.2 => not found

Unfortunately we're still missing dependencies, so we have some more packages to find and install:
Code: Select all
root@vmware-slackware:~# slackpkg file-search "libXxf86vm.so.1|libdrm.so.2"

Looking for libXxf86vm.so.1|libdrm.so.2 in package list. Please wait... DONE

The list below shows the packages that contains "libXxf86vm\.so\.1|libdrm\.so\.2" file.

[uninstalled] - libXxf86vm-1.1.1-i486-1
[uninstalled] - libdrm-2.4.23-i486-1

You can search specific packages using "slackpkg search package".


Not the package1 OR package2 syntax to search for multiple files, which is a bit counter intuitive to how the install sub command handles multiple packages:
Code: Select all
root@vmware-slackware:~# slackpkg install libXxf86vm libdrm               
...
Installing libXxf86vm-1.1.1-i486-1...
Verifying package libXxf86vm-1.1.1-i486-1.txz.
Installing package libXxf86vm-1.1.1-i486-1.txz:
PACKAGE DESCRIPTION:
# libXxf86vm
#
# libXxf86vm is part of X11.
#
# For more information about the X.Org Foundation (the providers of the
# X.Org implementation of the X Window System), see their website:
#
# http://www.x.org
#
Executing install script for libXxf86vm-1.1.1-i486-1.txz.
Package libXxf86vm-1.1.1-i486-1.txz installed.
...
Installing libXxf86vm-1.1.1-i486-1...
Verifying package libXxf86vm-1.1.1-i486-1.txz.
Installing package libXxf86vm-1.1.1-i486-1.txz:
PACKAGE DESCRIPTION:
# libXxf86vm
#
# libXxf86vm is part of X11.
#
# For more information about the X.Org Foundation (the providers of the
# X.Org implementation of the X Window System), see their website:
#
# http://www.x.org
#
Executing install script for libXxf86vm-1.1.1-i486-1.txz.
Package libXxf86vm-1.1.1-i486-1.txz installed.

You may have to repeat this process for other missing libraries, depending on how minimal your slackware installation is. Once no libraries are reported missing you can run FAHClient:
Code: Select all
bas@vmware-slackware:~/software/folding-fah7$ ldd FAHClient | grep "not found"
bas@vmware-slackware:~/software/folding-fah7$ ./FAHClient --version
7.1.38


Running FAHControl will require additional X related packages, more on that later.
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby jimerickson » Thu Jan 05, 2012 8:29 pm

thank you smoking2000
jimerickson
 
Posts: 533
Joined: Wed May 28, 2008 12:56 am
Location: ames, iowa

Re: gentoo & v7?

Postby smoking2000 » Thu Jan 05, 2012 8:41 pm

Except that you ware asking for Gentoo, which is not quite the same as slackware :oops:

The ldd trick to find missing dependencies is the same, but you'll obviously have the install them with emerge.
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby smoking2000 » Thu Jan 05, 2012 9:00 pm

On Gentoo you can use equery (part of the gentoolkit ebuild) to find the packages using the filenames from the ldd output. It only doesn't build on my VM at the moment, so I can't provide examples now.
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby jimerickson » Thu Jan 05, 2012 9:04 pm

thanks again smoking2000!! that should get me started.
jimerickson
 
Posts: 533
Joined: Wed May 28, 2008 12:56 am
Location: ames, iowa

Re: gentoo & v7?

Postby jimerickson » Sat Jan 14, 2012 7:00 pm

thanks for your help smoking2000! i got it running on gentoo. just make sure python is compiled with the sqlite use flag and emerge pygtk and it all worked for me.
jimerickson
 
Posts: 533
Joined: Wed May 28, 2008 12:56 am
Location: ames, iowa

Re: gentoo & v7?

Postby darkbasic » Sat Jan 14, 2012 7:21 pm

I will wait for the V7 ebuild, in the meanwhile nobody will notice the absence of my 1,4GHz Core 2 Duo ULV laptop :lol:
darkbasic
 
Posts: 90
Joined: Sun Jan 08, 2012 12:50 pm

Re: gentoo & v7?

Postby smoking2000 » Sun Jan 15, 2012 3:08 pm

It will be hard getting FAHClient v7.1.43 to run on Gentoo. The current version of openssl in Portage is 1.0.0e, while FAHClient is build with openssl 0.9.8, so the libssl dependencies cannot be satisfied:
Code: Select all
*  dev-libs/openssl
      Latest version available: 1.0.0e
      Latest version installed: 1.0.0e
      Size of files: 3,949 kB
      Homepage:      http://www.openssl.org/
      Description:   full-strength general purpose cryptography library (including SSL v2/v3 and TLS v1)
      License:       openssl

bas@vmware-gentoo ~/software/folding-fah7/fahclient-7.1.43-32bit-release $ ldd FAHClient  | grep "not found"
        libssl.so.0.9.8 => not found
        libcrypto.so.0.9.8 => not found

Since the souce for FAHClient & FAHViewer is not available, it cannot be rebuild with the newer version available in Portage.

Writing an ebuild for FAHControl will most likely be easier.
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby darkbasic » Sun Jan 15, 2012 3:22 pm

I will never understand why they aren't releasing fahclient sources... What's the point except causing problems?
darkbasic
 
Posts: 90
Joined: Sun Jan 08, 2012 12:50 pm

Re: gentoo & v7?

Postby smoking2000 » Sun Jan 15, 2012 3:52 pm

One good argument I've heard for keeping the source for FAHClient and its cores closed is to guarantee the correctness of the WU results, having a well defined and controlled environment in which the simulations can be reproduced for verification.

The Work Servers have also shown to be sensitive to disruptions with long rebuild times of the RAID sets attached to them when they crash. Not having people debug their fahclient modifications in the production environment helps keeps the system and project adminis sane :)

I may have spoken too soon regarding the difficulty of getting libssl 0.9.8 installed, the portage directory for dev-libs/openssl contains an ebuild for openssl 0.9.8r & 0.9.8s which can be installed to satisfy the FAHClient dependency:
Code: Select all
vmware-gentoo ~ # emerge /usr/portage/dev-libs/openssl/openssl-0.9.8s.ebuild
*** emerging by path is broken and may not always work!!!

Calculating dependencies \
*** You are emerging a masked package. It is MUCH better to use
*** /etc/portage/package.* to accomplish this. See portage(5) man
*** page for details.
>>> Waiting 10 seconds before starting...
...
>>> Verifying ebuild manifests

>>> Emerging (1 of 1) dev-libs/openssl-0.9.8s
>>> Downloading 'http://distfiles.gentoo.org/distfiles/openssl-0.9.8s.tar.gz'
...
>>> Source compiled.
>>> Test phase [not enabled]: dev-libs/openssl-0.9.8s

>>> Install openssl-0.9.8s into /var/tmp/portage/dev-libs/openssl-0.9.8s/image/ category dev-libs
>>> Completed installing openssl-0.9.8s into /var/tmp/portage/dev-libs/openssl-0.9.8s/image/

strip: i686-pc-linux-gnu-strip --strip-unneeded -R .comment
   usr/lib/libssl.so.0.9.8
   usr/lib/libcrypto.so.0.9.8

>>> Installing (1 of 1) dev-libs/openssl-0.9.8s

>>> Recording dev-libs/openssl::gentoo in "world" favorites file...

 * Messages for package dev-libs/openssl-0.9.8s:

 * Removing lib{crypto,ssl}.so.0.9.8 to avoid collision with openssl-1
>>> Auto-cleaning packages...

>>> No outdated packages were found on your system.

 * GNU info directory index is up-to-date.

The modules are now found, but the linker complains about the lack of version information. FAHClient does appear to run:
Code: Select all
bas@vmware-gentoo ~/software/folding-fah7/fahclient-7.1.43-32bit-release $ ldd FAHClient  | grep "not found"
./FAHClient: /usr/lib/libssl.so.0.9.8: no version information available (required by ./FAHClient)
./FAHClient: /usr/lib/libcrypto.so.0.9.8: no version information available (required by ./FAHClient)
bas@vmware-gentoo ~/software/folding-fah7/fahclient-7.1.43-32bit-release $ ./FAHClient --version
./FAHClient: /usr/lib/libssl.so.0.9.8: no version information available (required by ./FAHClient)
./FAHClient: /usr/lib/libcrypto.so.0.9.8: no version information available (required by ./FAHClient)
7.1.43
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby smoking2000 » Sat Jan 21, 2012 1:40 am

I wrote an ebuild for FAHClient v7.1.43, using the .tar.bz2 releases and the init script from the Debian package (which I presume is redistributable; it would be nice to have it included in the tarball as example-init.d):

- fahclient-7.1.43.ebuild
- files/default
- files/init
- Manifest

You can download these files into your local portage overlay.

If you don't have a local portage overlay yet, you can create one with:
Code: Select all
# mkdir -p /usr/local/portage/profiles
# echo "$HOSTNAME" >> /usr/local/portage/profiles/repo_name
# chown root:portage /usr/local/portage
# chmod g+s /usr/local/portage
# chmod 775 /usr/local/portage
# echo "PORTDIR_OVERLAY=\"\${PORTDIR_OVERLAY} /usr/local/portage/\"" >> /etc/make.conf

Import the files into your overlay:
Code: Select all
# mkdir -p /usr/local/portage/sci-chemistry/fahclient/files
# for FILE in Manifest fahclient-7.1.43.ebuild files/default files/init; do wget http://linuxminded.nl/tmp/fahclient-7.1.43-ebuild/$FILE -O /usr/local/portage/sci-chemistry/fahclient/$FILE; done

And install the ebuild, while ignoring the unverifiable SSL certificate:
Code: Select all
# FETCHCOMMAND="wget --no-check-certificate \${URI} -O \${DISTDIR}/\${FILE}" emerge fahclient


I'm not sure if I'll keep maintaining the ebuild with new releases as I don't use Gentoo in daily life. An actual Gentoo user or developer is better suited to maintain FAH ebuilds.

It was a fun exercise in developing ebuilds for Gentoo, although mangling binary packages isn't nearly as fun as hacking the source (which only fahcontrol allows). :eugeek:
User avatar
smoking2000
 
Posts: 471
Joined: Mon Dec 03, 2007 7:20 am
Location: Amsterdam

Re: gentoo & v7?

Postby jimerickson » Sat Jan 21, 2012 2:26 am

thanks!!
jimerickson
 
Posts: 533
Joined: Wed May 28, 2008 12:56 am
Location: ames, iowa

Re: gentoo & v7?

Postby darkbasic » Sun Jan 22, 2012 3:25 pm

Thanks, my laptop is folding now :)
darkbasic
 
Posts: 90
Joined: Sun Jan 08, 2012 12:50 pm

Next

Return to V7.1.52 Windows/Linux

Who is online

Users browsing this forum: No registered users and 3 guests

cron