[EMBOSS] Does not manage to use .embossrc from the current directory.

Charles Plessy charles-listes-emboss at plessy.org
Thu Apr 26 01:01:37 UTC 2007


Dear EMBOSS programmers,

I am using EMBOSS in a context where I can not expect $HOME to be set.
Therefore, I created a .embossrc from a template and attempted to use it in the
current directory. However, EMBOSS does not seem to read it, despite what is
written in the documentation:

http://emboss.sourceforge.net/docs/adminguide/node4.html

Here is an example:

# The template:

sorbet【tmp】$ cat mirbase.embossrc
DB mirbase [
  type: N
  format: embl
  method: emblcd
  directory: /usr/share/mirbase/emboss
  file: *.dat
]

# Creation of the .embossrc:

sorbet【tmp】$ PWD=`pwd` perl -pe "s(/usr/share/mirbase/emboss)($PWD)" < mirbase.embossrc | tee .embossrc
DB mirbase [
  type: N
  format: embl
  method: emblcd
  directory: /home/charles/tmp
  file: *.dat
]

# It does not work, but the .embossrc is functional in $HOME

sorbet【tmp】$ seqret mirbase:MI0000007 stdout
Reads and writes (returns) sequences
Error: Failed to open filename 'mirbase'
Error: Unable to read sequence 'mirbase:MI0000007'
Died: seqret terminated: Bad value for '-sequence' and no prompt

sorbet【tmp】$ cp .embossrc $HOME

sorbet【tmp】$ seqret mirbase:MI0000007 stdout
Reads and writes (returns) sequences
>cel-mir-36 MI0000007 Caenorhabditis elegans miR-36 stem-loop
caccgcugucggggaaccgcgccaauuuucgcuucagugcuagaccauccaaagugucua
ucaccgggugaaaauucgcauggguccccgacgcgga

# Strace confirms that the current dir is not searched for .embossrc

sorbet【tmp】$ rm $HOME/.embossrc

sorbet【tmp】$ strace seqret mirbase:MI0000007 stdout 2>&1 | grep embossrc
open("/home/charles/.embossrc", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)

sorbet【tmp】$ strace seqret mirbase:MI0000007 stdout 2>&1 | grep emboss.default
open("/usr/share/EMBOSS/emboss.default", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)
open("/home/charles/debian/EMBOSS-4.1.0/emboss/emboss.default", O_RDONLY|O_LARGEFILE) = -1 ENOENT (No such file or directory)

Interestingly, it searches also emboss.default in a place which is not
expected: where I compiled EMBOSS... Can I have made a mistake at compilation
time which would prevent `pwd`/.embossrc to be parsed?

Have a nice day,

-- 
Charles Plessy
Debian-Med packaging team
http://www.debian.org/devel/debian-med/
Wako, Saitama, Japan



More information about the EMBOSS mailing list