Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 266305 - dev-texlive/texlive-basic-2008 failed: portage/dev-texlive/texlive-basic-2008/work/texmf-var/web2c does not exist
Summary: dev-texlive/texlive-basic-2008 failed: portage/dev-texlive/texlive-basic-2008...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Alexis Ballier
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-04-15 20:33 UTC by Robert Wolf
Modified: 2009-04-17 13:10 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Wolf 2009-04-15 20:33:58 UTC
Compilation of dev-texlive/texlive-basic-2008 fails because of non-existing directory texlive-basic-2008/work/texmf-var/web2c used in fmtutil command. The reason is:

fmtutil runs following to create the directory

---
/var/lib/texmf/web2c/mktexdir /portage.work/portage/dev-texlive/texlive-basic-2008/work/texmf-var/web2c
---

but the /var/lib/texmf/web2c/mktexdir does not exist

The path /var/lib/texmf reads fmtutil from output of command kpsewhich --var-value=TEXMFMAIN.

kpsewhich reads the value of TEXMFMAIN from /usr/share/texmf/web2c/texmf.cnf (which should be symlink to /etc/texmf/web2c/texmf.cnf).

In the file /etc/texmf/web2c/texmf.cnf there is a definition:
TEXMFMAIN = /var/lib/texmf

But if I grep the file /etc/texmf/web2c/texmf.cnf for TEXMFMAIN, I get TEXMFMAIN = /var/lib/texmf
TEXMFMAIN = $SELFAUTODIR/share/texmf

The file /etc/texmf/web2c/texmf.cnf is generated using texmf-update. texmf-update generates this file from files *.cnf stored in /etc/texmf/texmf.d

Probably there were two CNF file with TEXMFMAIN definition. The file with correct TEXMFMAIN (05searchpaths.cnf) belongs to texlive-core and the file with incorrect TEXMFMAIN (00texmf.cnf) belongs to tetex.

Because texlive-core has been installed sooner as tetex uninstalled, texmf-update generated the web2c/texmf.cnf with these two TEXMFMAIN variables, unfortunately with the incorrect as first.

Later has been installed texlive-basic and just before this merge, tetex has been unmerged. Bot nothing has started texmfs-update again to regenerate new web2c/texmf.cnd. And the incorrect TEXMFMAIN path remains.

Even if I did clean uninstall according to TeX Live 2008 guide (http://www.gentoo.org/proj/en/tex/texlive-migration-guide.xml#uninstall), the emerge fails. On my system is the variable TEXMFMAIN in the file /etc/texmf/web2c/texmf.cnf set still to /var/lib/texmf.

IMHO this problem can arise only if one make upgrades regulary and he installed texlive-core one day and later he installed texlive-basic which uninstalled tetex. If someone makes updates irregulary, and he makes upgrade now, the portage (maybe) first unmerge tetex (deletes the 00texmf.cnf file) and then installs texlive-core (with 05searchpaths.cnf and correct TEXMFMAIN) and generates texmf.cnf. Then everything is fine and texlive-basic installs correct too. Probably texlive-core should be blocked by tetex, or texlive-core should be stable after tetex masking.

The solution for this problem is easy. If you see this error, run texmf-update and check the output of kpsewhich --var-value=TEXMFMAIN again, it should return /usr/share/texmf now. I did this and texlive-basic has been installed without any problem.

There is a section in TeXlive migration guide about this error, but it says not right. 

"There is no magic command to fix this one, you should check that your configuration is correct..."

Where to check what? I hope I can say, I am an advanced user, Linux Admin (not Linux OS geek). I could find all this problem using strace and my knowledge. But normal user is not able to do all this. I have made no changes to my tex configuration (as many normal users) and it does not work. There is not written in migration guide, what exactly check how.

"...that there are no stray configuration files in /etc/texmf/texmf.d. This will most likely be due to an old 00texmf.cnf being still there and thus setting wrong definitions for the texmf.cnf file."

I did not created my own files and uninstalling tetex deleted the 00texmf.cnf file. The file 00texmf.cnf is not present.

"...and remember that when you modify or remove a file in /etc/texmf/*.d you need to run texmf-update to have the changes taken into account."

I have not modified neither added nor removed any file in/to/from /etc/texmf/*.d directories. Still I HAVE TO RUN texmf-update, because texlive-core did it too soon (before tetex unmerge).

Sorry for this Bug Report, it is not ordinary bug report because solution is written in this report, so you can close it as solved or invalid, as I have written, if someone updates whole texlive-core & texlive-basic now (and it unmerge first tetex), the problem should never arise. But for people they already installed texlive-core together with tetex and now they are unable to install texlive-basic this can help.
Comment 1 Alexis Ballier gentoo-dev 2009-04-16 09:51:24 UTC
(In reply to comment #0)
> Because texlive-core has been installed sooner as tetex uninstalled,

???
they block each other, I fail to see how this can happen...

> Even if I did clean uninstall according to TeX Live 2008 guide
> (http://www.gentoo.org/proj/en/tex/texlive-migration-guide.xml#uninstall), the
> emerge fails. On my system is the variable TEXMFMAIN in the file
> /etc/texmf/web2c/texmf.cnf set still to /var/lib/texmf.

The guide is meant to be read *before* proceeding with installing texlive... if you do it the way "do first, think later" you get into troubles; the problem you describe is only happening because you haven't read the documentation; I know it's annoying but it is a required step to have a nice migration.

> Probably texlive-core should be blocked by tetex, or texlive-core should
> be stable after tetex masking.

I'm affraid this is already the case...


> "There is no magic command to fix this one, you should check that your
> configuration is correct..."
>
> Where to check what?

Section 3, configuration in the guide?

> Sorry for this Bug Report, it is not ordinary bug report because solution is
> written in this report, so you can close it as solved or invalid, as I have
> written, if someone updates whole texlive-core & texlive-basic now (and it
> unmerge first tetex), the problem should never arise.

The problem arises because people do not read the documentation; and unfortunately you're not the first one by far and very likely not the last one...

> But for people they
> already installed texlive-core together with tetex

this is impossible because tl-core blocks tetex, they collide like hell (or it is a package manager bug)
Comment 2 Robert Wolf 2009-04-16 11:12:39 UTC
(In reply to comment #1)
> (In reply to comment #0)
> > Because texlive-core has been installed sooner as tetex uninstalled,
> 
> ???
> they block each other, I fail to see how this can happen...

*** Ha, then, I don't understand either, but my qlop (emerge log) says:

Tue Apr  7 17:16:11 2009 >>> app-text/texlive-core-2008-r4
Tue Apr  7 17:16:17 2009 >>> virtual/tex-base-0
Tue Apr  7 17:16:35 2009 >>> dev-texlive/texlive-documentation-base-2008
Wed Apr  8 11:44:44 2009 <<< app-text/tetex-3.0_p1-r6
Wed Apr  8 11:49:35 2009 >>> dev-texlive/texlive-basic-2008

texlive-core has been installed before tetex unstalled

> > Even if I did clean uninstall according to TeX Live 2008 guide
> > (http://www.gentoo.org/proj/en/tex/texlive-migration-guide.xml#uninstall), the
> > emerge fails. On my system is the variable TEXMFMAIN in the file
> > /etc/texmf/web2c/texmf.cnf set still to /var/lib/texmf.
> 
> The guide is meant to be read *before* proceeding with installing texlive... if
> you do it the way "do first, think later" you get into troubles; the problem
> you describe is only happening because you haven't read the documentation; I
> know it's annoying but it is a required step to have a nice migration.

*** Hmmm, but texlive-core writes the info about migration guide at end of installation.
 
> > Probably texlive-core should be blocked by tetex, or texlive-core should
> > be stable after tetex masking.
> 
> I'm affraid this is already the case...

*** Hmmm, I see it now ... but texlive-core has been installed together with tetex ...
 

> > "There is no magic command to fix this one, you should check that your
> > configuration is correct..."
> >
> > Where to check what?
> 
> Section 3, configuration in the guide?

*** It describes how to configure, but not where to search this problem.
 
> The problem arises because people do not read the documentation; and
> unfortunately you're not the first one by far and very likely not the last
> one...

*** hmmm, but the texlive-core has been installed together with tetex ... it was the problem ... I don't understand, why tetex has not been uninstalled before texlive-core

> > But for people they
> > already installed texlive-core together with tetex
> 
> this is impossible because tl-core blocks tetex, they collide like hell (or it
> is a package manager bug)

Probably something was wrong.
Comment 3 Alexis Ballier gentoo-dev 2009-04-16 17:23:38 UTC
(In reply to comment #2)
> (In reply to comment #1)
> > (In reply to comment #0)
> > > Because texlive-core has been installed sooner as tetex uninstalled,
> > 
> > ???
> > they block each other, I fail to see how this can happen...
> 
> *** Ha, then, I don't understand either, but my qlop (emerge log) says:
> 
> Tue Apr  7 17:16:11 2009 >>> app-text/texlive-core-2008-r4
> Tue Apr  7 17:16:17 2009 >>> virtual/tex-base-0
> Tue Apr  7 17:16:35 2009 >>> dev-texlive/texlive-documentation-base-2008
> Wed Apr  8 11:44:44 2009 <<< app-text/tetex-3.0_p1-r6
> Wed Apr  8 11:49:35 2009 >>> dev-texlive/texlive-basic-2008
> 
> texlive-core has been installed before tetex unstalled

@portage team: how can this happen?

I'm leaving this as invalid as, really, the guide is meant to be read before migrating; that tl-core gives warnings at the end is only to remind people about this and shouldn't be the first time you see this if you're migrating.
Comment 4 Zac Medico gentoo-dev 2009-04-16 20:51:35 UTC
(In reply to comment #3)
> (In reply to comment #2)
> > texlive-core has been installed before tetex unstalled
> 
> @portage team: how can this happen?

You should use the new EAPI 2 !!atom blocker syntax if the package has to be uninstalled _before_. The !atom syntax means that the blocked package should be uninstalled _after_.
Comment 5 Robert Wolf 2009-04-17 13:10:30 UTC
(In reply to comment #4)
> (In reply to comment #3)
> > (In reply to comment #2)
> > > texlive-core has been installed before tetex unstalled
> > 
> > @portage team: how can this happen?
> 
> You should use the new EAPI 2 !!atom blocker syntax if the package has to be
> uninstalled _before_. The !atom syntax means that the blocked package should be
> uninstalled _after_.

OK, this could be the reason.

But still, it is a strage. I did a big upgrade (31 packages)

2009/4/7 16:59:27:  >>> emerge (19 of 31) app-text/texlive-core-2008-r4 to /
2009/4/7 16:59:31:  === (19 of 31) Cleaning (app-text/texlive-core-2008-r4::/usr/portage/app-text/texlive-core/texlive-core-2008-r4.ebuild)
2009/4/7 16:59:31:  === (19 of 31) Compiling/Merging (app-text/texlive-core-2008-r4::/usr/portage/app-text/texlive-core/texlive-core-2008-r4.ebuild)
2009/4/7 17:15:44:  === (19 of 31) Merging (app-text/texlive-core-2008-r4::/usr/portage/app-text/texlive-core/texlive-core-2008-r4.ebuild)
2009/4/7 17:16:11:  === (19 of 31) Post-Build Cleaning (app-text/texlive-core-2008-r4::/usr/portage/app-text/texlive-core/texlive-core-2008-r4.ebuild)
2009/4/7 17:16:11:  ::: completed emerge (19 of 31) app-text/texlive-core-2008-r4 to /
2009/4/7 17:16:11:  >>> emerge (20 of 31) virtual/tex-base-0 to /
2009/4/7 17:16:13:  === (20 of 31) Cleaning (virtual/tex-base-0::/usr/portage/virtual/tex-base/tex-base-0.ebuild)
2009/4/7 17:16:13:  === (20 of 31) Compiling/Merging (virtual/tex-base-0::/usr/portage/virtual/tex-base/tex-base-0.ebuild)
2009/4/7 17:16:15:  === (20 of 31) Merging (virtual/tex-base-0::/usr/portage/virtual/tex-base/tex-base-0.ebuild)
2009/4/7 17:16:17:  === (20 of 31) Post-Build Cleaning (virtual/tex-base-0::/usr/portage/virtual/tex-base/tex-base-0.ebuild)
2009/4/7 17:16:17:  ::: completed emerge (20 of 31) virtual/tex-base-0 to /
2009/4/7 17:16:18:  >>> emerge (21 of 31) dev-texlive/texlive-documentation-base-2008 to /
2009/4/7 17:16:21:  === (21 of 31) Cleaning (dev-texlive/texlive-documentation-base-2008::/usr/portage/dev-texlive/texlive-documentation-base/texlive-documentation-base-2008.ebuild)
2009/4/7 17:16:21:  === (21 of 31) Compiling/Merging (dev-texlive/texlive-documentation-base-2008::/usr/portage/dev-texlive/texlive-documentation-base/texlive-documentation-base-2008.ebuild)
2009/4/7 17:16:23:  === (21 of 31) Merging (dev-texlive/texlive-documentation-base-2008::/usr/portage/dev-texlive/texlive-documentation-base/texlive-documentation-base-2008.ebuild)
2009/4/7 17:16:35:  === (21 of 31) Post-Build Cleaning (dev-texlive/texlive-documentation-base-2008::/usr/portage/dev-texlive/texlive-documentation-base/texlive-documentation-base-2008.ebuild)
2009/4/7 17:16:35:  ::: completed emerge (21 of 31) dev-texlive/texlive-documentation-base-2008 to /
2009/4/7 17:16:35:  >>> emerge (22 of 31) dev-texlive/texlive-basic-2008 to /
2009/4/7 17:16:38:  === (22 of 31) Cleaning (dev-texlive/texlive-basic-2008::/usr/portage/dev-texlive/texlive-basic/texlive-basic-2008.ebuild)
2009/4/7 17:16:38:  === (22 of 31) Compiling/Merging (dev-texlive/texlive-basic-2008::/usr/portage/dev-texlive/texlive-basic/texlive-basic-2008.ebuild)
2009/4/7 17:16:45:  === (22 of 31) Merging (dev-texlive/texlive-basic-2008::/usr/portage/dev-texlive/texlive-basic/texlive-basic-2008.ebuild)
2009/4/7 17:16:56:  *** Finished. Cleaning up...
2009/4/7 17:16:56:  *** exiting unsuccessfully with status '1'.
2009/4/7 17:17:10:  *** terminating.

So for some reason, texlive-basic-2008 crashed. But in Log, I can see only

Transcript written on tex.log.
fmtutil: /home/GENTOO/work/portage/dev-texlive/texlive-basic-2008/work/texmf-var/web2c/tex/tex.fmt installed.
 * Format metafont already built.
 * Format tex already built.
>>> Source compiled.
>>> Test phase [not enabled]: dev-texlive/texlive-basic-2008

>>> Install texlive-basic-2008 into /home/GENTOO/work/portage/dev-texlive/texlive-basic-2008/image/ category dev-texlive
 * Symlink mf -> mf-nowin skipped (texlive-core takes care of it)
 * Symlink tex -> tex skipped
>>> Completed installing texlive-basic-2008 into /home/GENTOO/work/portage/dev-texlive/texlive-basic-2008/image/

ecompressdir: bzip2 -9 /usr/share/texmf/doc/man
 * checking 1094 files for package collisions
1000 files checked ...

and no error message, I think this was because of file collisions and therefore I manually removed tetex and then I did the solution with mkdir in eclass file.