2

I'm using yum for most packages, but one exception is texlive. However, a few packages (R, lyx, ...) will try to install through yum at each upgrade. I followed this solution, but it sometimes doesn't work; yum still tries to install texlive.

Can someone telle me what is wrong with my "faking" ?

Here's my texlive-fake.spec file:

Name: texlive-fake 
Version: 1.0 
Release: 1%{?dist} 
Summary: This is a fake TeXLive package 
Group: Applications/Publishing 
License: GPLv2 and BSD and Public Domain and LGPLv2+ and GPLv2+ and LPPL 
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)

Provides: config(texlive) 
Provides: kpathsea libkpathsea.so.4() 
Provides: tetex tetex-dvips tetex-fonts tetex-latex tex 
Provides: tex(dvips) tex(latex) tex(tex) tex-preview texinfo-tex 
Provides: texlive texlive-afm texlive-context texlive-doc texlive-doc-errata 
Provides: texlive-dvips texlive-dviutils texlive-east-asian texlive-fonts 
Provides: texlive-texmf texlive-latex texlive-utils texlive-xetex 
Provides: texlive-texmf-afm texlive-texmf-context texlive-texmf-doc texlive-texmf-dvips 
Provides: texlive-texmf-errata texlive-texmf-errata-afm texlive-texmf-errata-context 
Provides: texlive-texmf-errata-doc texlive-texmf-errata-dvips texlive-texmf-errata-east-asian 
Provides: texlive-texmf-errata-fonts texlive-texmf-errata-latex texlive-texmf-errata-xetex 
Provides: texlive-texmf-fonts texlive-texmf-latex texlive-texmf-xetex 
Provides: tex(ptmro8t.tfm) tex(ptmri8t.tfm) tex(ptmr8t.tfm) tex(ptmb8t.tfm) tex(phvr8t.tfm) 
Provides: tex(pcrr8t.tfm) tex(inconsolata.sty) tex(ecrm1000.tfm) tex(cm-super-ts1.enc)
Provides: texlive-algorithms
Provides: texlive-amsfonts
Provides: texlive-amsmath
Provides: texlive-attachfile
Provides: texlive-babel
Provides: texlive-babelbib
Provides: texlive-base
Provides: texlive-bera
Provides: texlive-booktabs
Provides: texlive-breakurl
Provides: texlive-caption
Provides: texlive-carlisle
Provides: texlive-chngcntr
Provides: texlive-colortbl
Provides: texlive-csquotes
Provides: texlive-currfile
Provides: texlive-dvipdfm
Provides: texlive-dvipdfm-bin
Provides: texlive-enumitem
Provides: texlive-eso-pic
Provides: texlive-etex-pkg
Provides: texlive-etoolbox
Provides: texlive-fancyvrb
Provides: texlive-filecontents
Provides: texlive-filehook
Provides: texlive-float
Provides: texlive-fontspec
Provides: texlive-footmisc
Provides: texlive-fp
Provides: texlive-geometry
Provides: texlive-graphics
Provides: texlive-hyperref
Provides: texlive-hyphen-base
Provides: texlive-ifetex
Provides: texlive-ifxetex
Provides: texlive-index
Provides: texlive-kastrup
Provides: texlive-koma-script
Provides: texlive-kpathsea
Provides: texlive-kpathsea-bin
Provides: texlive-kpathsea-lib
Provides: texlive-l3kernel
Provides: texlive-l3packages
Provides: texlive-latex
Provides: texlive-latex-fonts
Provides: texlive-latexconfig
Provides: texlive-listings
Provides: texlive-lm
Provides: texlive-lualatex-math
Provides: texlive-luaotfload
Provides: texlive-luaotfload-bin
Provides: texlive-luatex
Provides: texlive-luatex-bin
Provides: texlive-luatexbase
Provides: texlive-marginnote
Provides: texlive-memoir
Provides: texlive-mparhack
Provides: texlive-ms
Provides: texlive-multido
Provides: texlive-oberdiek
Provides: texlive-paralist
Provides: texlive-parallel
Provides: texlive-pdftex
Provides: texlive-pdftex-bin
Provides: texlive-pgf
Provides: texlive-psnfss
Provides: texlive-pst-3d
Provides: texlive-pst-coil
Provides: texlive-pst-eps
Provides: texlive-pst-fill
Provides: texlive-pst-grad
Provides: texlive-pst-math
Provides: texlive-pst-node
Provides: texlive-pst-plot
Provides: texlive-pst-text
Provides: texlive-pst-tree
Provides: texlive-pstricks
Provides: texlive-pstricks-add
Provides: texlive-qstest
Provides: texlive-sauerj
Provides: texlive-setspace
Provides: texlive-showexpl
Provides: texlive-soul
Provides: texlive-subfig
Provides: texlive-tetex
Provides: texlive-tetex-bin
Provides: texlive-thumbpdf
Provides: texlive-thumbpdf-bin
Provides: texlive-tipa
Provides: texlive-tools
Provides: texlive-ulem
Provides: texlive-underscore
Provides: texlive-unicode-math
Provides: texlive-url
Provides: texlive-varwidth
Provides: texlive-xcolor
Provides: texlive-xkeyval
Provides: texlive-xunicode

%description 

This was necessary to have a tlmgr-based installation of texlive and all the rpm packages that requires texlive (e.g., a2ps and R-core) still installable.

%prep

%build

%install 

rm -rf $RPM_BUILD_ROOT

%clean 

rm -rf $RPM_BUILD_ROOT

%files 

%defattr(-,root,root,-) 

%doc

%changelog

It is installed: #rpm -qa | grep texlive texlive-fake-1.0-1.el7.local.x86_64

However, yum update lyx wants to install texlive for dependencies:

================================================================================
 Package               Arch   Version                                Repository
                                                                           Size
================================================================================
Updating:
 lyx                   x86_64 2.1.4-7.el7                            epel 4.1 M
Installing for dependencies:
 texlive-algorithms    noarch 2:svn15878.0.1-38.el7                  base  21 k
 texlive-amsfonts      noarch 2:svn29208.3.04-38.el7                 base 3.6 M
 texlive-amsmath       noarch 2:svn29327.2.14-38.el7                 base  49 k
 texlive-attachfile    noarch 2:svn21866.v1.5b-38.el7                base  21 k
 texlive-babel         noarch 2:svn24756.3.8m-38.el7                 base 129 k
 texlive-babelbib      noarch 2:svn25245.1.31-38.el7                 base  49 k
 texlive-bera          noarch 2:svn20031.0-38.el7                    base 347 k
 texlive-booktabs      noarch 2:svn15878.1.61803-38.el7              base  19 k
 texlive-breakurl      noarch 2:svn15878.1.30-38.el7                 base  20 k
 texlive-caption       noarch 2:svn29026.3.3__2013_02_03_-38.el7     base  51 k
 texlive-carlisle      noarch 2:svn18258.0-38.el7                    base  29 k
 texlive-chngcntr      noarch 2:svn17157.1.0a-38.el7                 base  19 k
 texlive-colortbl      noarch 2:svn25394.v1.0a-38.el7                base  20 k
 texlive-csquotes      noarch 2:svn24393.5.1d-38.el7                 base  36 k
 texlive-currfile      noarch 2:svn29012.0.7b-38.el7                 base  21 k
 texlive-dvipdfm       noarch 2:svn26689.0.13.2d-38.el7              base  23 k
 texlive-dvipdfm-bin   noarch 2:svn13663.0-38.20130427_r30134.el7    base  18 k
 texlive-enumitem      noarch 2:svn24146.3.5.2-38.el7                base  29 k
 texlive-eso-pic       noarch 2:svn21515.2.0c-38.el7                 base  21 k
 texlive-etex-pkg      noarch 2:svn15878.2.0-38.el7                  base  22 k
 texlive-etoolbox      noarch 2:svn20922.2.1-38.el7                  base  25 k
 texlive-fancyvrb      noarch 2:svn18492.2.8-38.el7                  base  30 k
 texlive-filecontents  noarch 2:svn24250.1.3-38.el7                  base  19 k
 texlive-filehook      noarch 2:svn24280.0.5d-38.el7                 base  22 k
 texlive-float         noarch 2:svn15878.1.3d-38.el7                 base  20 k
 texlive-fontspec      noarch 2:svn29412.v2.3a-38.el7                base  38 k
 texlive-footmisc      noarch 2:svn23330.5.5b-38.el7                 base  23 k
 texlive-fp            noarch 2:svn15878.0-38.el7                    base  39 k
 texlive-geometry      noarch 2:svn19716.5.6-38.el7                  base  26 k
 texlive-graphics      noarch 2:svn25405.1.0o-38.el7                 base  33 k
 texlive-hyperref      noarch 2:svn28213.6.83m-38.el7                base 139 k
 texlive-hyphen-base   noarch 2:svn29197.0-38.el7                    base  39 k
 texlive-ifetex        noarch 2:svn24853.1.2-38.el7                  base  18 k
 texlive-ifxetex       noarch 2:svn19685.0.5-38.el7                  base  18 k
 texlive-index         noarch 2:svn24099.4.1beta-38.el7              base  29 k
 texlive-kastrup       noarch 2:svn15878.0-38.el7                    base  18 k
 texlive-koma-script   noarch 2:svn27255.3.11b-38.el7                base 5.1 M
 texlive-kpathsea      noarch 2:svn28792.0-38.el7                    base 140 k
 texlive-l3kernel      noarch 2:svn29409.SVN_4469-38.el7             base 107 k
 texlive-l3packages    noarch 2:svn29361.SVN_4467-38.el7             base  36 k
 texlive-latex         noarch 2:svn27907.0-38.el7                    base 197 k
 texlive-latex-fonts   noarch 2:svn28888.0-38.el7                    base  42 k
 texlive-latexconfig   noarch 2:svn28991.0-38.el7                    base  26 k
 texlive-listings      noarch 2:svn15878.1.4-38.el7                  base 138 k
 texlive-lm            noarch 2:svn28119.2.004-38.el7                base  13 M
 texlive-lualatex-math noarch 2:svn29346.1.2-38.el7                  base  21 k
 texlive-luaotfload    noarch 2:svn26718.1.26-38.el7                 base 101 k
 texlive-luatex        noarch 2:svn26689.0.70.1-38.el7               base  37 k
 texlive-luatexbase    noarch 2:svn22560.0.31-38.el7                 base  27 k
 texlive-marginnote    noarch 2:svn25880.v1.1i-38.el7                base  20 k
 texlive-memoir        noarch 2:svn21638.3.6j_patch_6.0g-38.el7      base  97 k
 texlive-mparhack      noarch 2:svn15878.1.4-38.el7                  base  20 k
 texlive-ms            noarch 2:svn24467.0-38.el7                    base  24 k
 texlive-multido       noarch 2:svn18302.1.42-38.el7                 base  21 k
 texlive-oberdiek      noarch 2:svn26725.0-38.el7                    base 307 k
 texlive-paralist      noarch 2:svn15878.2.3b-38.el7                 base  21 k
 texlive-parallel      noarch 2:svn15878.0-38.el7                    base  21 k
 texlive-pdftex        noarch 2:svn29585.1.40.11-38.el7              base 140 k
 texlive-pgf           noarch 2:svn22614.2.10-38.el7                 base 468 k
 texlive-psnfss        noarch 2:svn23394.9.2a-38.el7                 base  45 k
 texlive-pst-3d        noarch 2:svn17257.1.10-38.el7                 base  21 k
 texlive-pst-coil      noarch 2:svn24020.1.06-38.el7                 base  21 k
 texlive-pst-eps       noarch 2:svn15878.1.0-38.el7                  base  20 k
 texlive-pst-fill      noarch 2:svn15878.1.01-38.el7                 base  21 k
 texlive-pst-grad      noarch 2:svn15878.1.06-38.el7                 base  21 k
 texlive-pst-math      noarch 2:svn20176.0.61-38.el7                 base  22 k
 texlive-pst-node      noarch 2:svn27799.1.25-38.el7                 base  40 k
 texlive-pst-plot      noarch 2:svn28729.1.44-38.el7                 base  36 k
 texlive-pst-text      noarch 2:svn15878.1.00-38.el7                 base  21 k
 texlive-pst-tree      noarch 2:svn24142.1.12-38.el7                 base  24 k
 texlive-pstricks      noarch 2:svn29678.2.39-38.el7                 base  97 k
 texlive-pstricks-add  noarch 2:svn28750.3.59-38.el7                 base  41 k
 texlive-qstest        noarch 2:svn15878.0-38.el7                    base  22 k
 texlive-sauerj        noarch 2:svn15878.0-38.el7                    base  23 k
 texlive-setspace      noarch 2:svn24881.6.7a-38.el7                 base  24 k
 texlive-showexpl      noarch 2:svn27790.v0.3j-38.el7                base  21 k
 texlive-soul          noarch 2:svn15878.2.4-38.el7                  base  23 k
 texlive-subfig        noarch 2:svn15878.1.3-38.el7                  base  24 k
 texlive-tetex         noarch 2:svn29585.3.0-38.el7                  base  88 k
 texlive-thumbpdf      noarch 2:svn26689.3.15-38.el7                 base  38 k
 texlive-tipa          noarch 2:svn29349.1.3-38.el7                  base 2.8 M
 texlive-tools         noarch 2:svn26263.0-38.el7                    base  62 k
 texlive-ulem          noarch 2:svn26785.0-38.el7                    base  26 k
 texlive-underscore    noarch 2:svn18261.0-38.el7                    base  22 k
 texlive-unicode-math  noarch 2:svn29413.0.7d-38.el7                 base  61 k
 texlive-url           noarch 2:svn16864.3.2-38.el7                  base  26 k
 texlive-varwidth      noarch 2:svn24104.0.92-38.el7                 base  21 k
 texlive-xcolor        noarch 2:svn15878.2.11-38.el7                 base  35 k
 texlive-xkeyval       noarch 2:svn27995.2.6a-38.el7                 base  27 k
 texlive-xunicode      noarch 2:svn23897.0.981-38.el7                base  44 k
Updating for dependencies:
 lyx-common            noarch 2.1.4-7.el7                            epel 7.5 M
 lyx-fonts             noarch 2.1.4-7.el7                            epel 166 k

Transaction Summary
================================================================================
Install             ( 90 Dependent packages)
Upgrade  1 Package  (+ 2 Dependent packages)

(Btw, I'm using CentOS 7)

  • Isn't the "fake" or equivalent rpm actually on ctan? I do not remember where – daleif May 12 '16 at 16:06
  • Btw why is it referring to svn in the version number? Perhaps LyX was packaged incorrectly – daleif May 12 '16 at 16:07
2

The texlive-dummy packages on CTAN seem, unfortunately, not to include the source code. Thus, while they claim to be released under the LPPL, they are in practice difficult or impossible to modify. Since they are distribution specific and none is provided for Fedora as such, it isn't clear how well they might work in this case.

To be honest, I had no idea any such packages were provided on CTAN. I am not certain what I based mine on, but here it is. I must have looked up instructions for building RPMs somewhere and I probably adapted parts of it from a fake package I built to satisfy Arch's pacman.

I originally installed this for TeX Live 2012 with the Fedora which was current at the time. Although I no longer have a machine with both Fedora and TeX Live, the installed package continued to work fine with TeX Live 2015 and all was well before I wiped the disk last week.

Save the following as texlive2015-dummy-Jos.spec.

Name:    texlive2015-dummy-Jos
Version: 1.0
Release: 2%{?dist}
Summary: This is a fake TeXLive package
Group:   Applications/Publishing
License: GPLv2 and BSD and Public Domain and LGPLv2+ and GPLv2+ and LPPL
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)                   
Provides: config(texlive)
Provides: kpathsea libkpathsea.so.4()
Provides: tetex tetex-dvips tetex-fonts tetex-latex tex 
Provides: tex(dvips) tex(latex) tex(tex) tex-preview texinfo-tex
Provides: texlive texlive-afm texlive-context texlive-doc texlive-doc-errata
Provides: texlive-dvips texlive-dviutils texlive-east-asian texlive-fonts
Provides: texlive-texmf texlive-latex texlive-utils texlive-xetex          
Provides: texlive-texmf-afm texlive-texmf-context texlive-texmf-doc texlive-texmf-dvips                               
Provides: texlive-texmf-errata texlive-texmf-errata-afm texlive-texmf-errata-context
Provides: texlive-texmf-errata-doc texlive-texmf-errata-dvips texlive-texmf-errata-east-asian
Provides: texlive-texmf-errata-fonts texlive-texmf-errata-latex texlive-texmf-errata-xetex                      
Provides: texlive-texmf-fonts texlive-texmf-latex texlive-texmf-xetex                             
Provides: tetex-IEEEtran tetex-dvipost tetex-elsevier tetex-tex4ht
Provides: tetex-xdvi xdvik

%description
This was necessary to have a tlmgr-based installation of texlive and all the rpm packages that requires texlive (e.g., a2ps and R-core) still installable.

%prep

%build

%install
rm -rf $RPM_BUILD_ROOT

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%doc

%changelog

To build:

  1. make a dummy directory;
  2. copy texlive2015-dummy-Jos.spec into the directory;
  3. cd into the directory;
  4. run rpmbuild -bb texlive2015-dummy-Jos.spec

The output will tell you where the .rpm is.

This works fine for installing Kile, for example, with the package manager. If LyX turns out to want to install additional things which TeX Live provides, add the relevant package names into the .spec, bump the release number (e.g. from 2 to 3), rebuild the .rpm and reinstall the package.

The advantage of this is that it can easily be extended and modified if Fedora's packaging changes or if additional packages become available and listed as dependencies for software you want to install through the package manager.

Do note that yum is deprecated. If you have a recent version of Fedora (e.g. 23+ - not sure about 22), dnf should be used instead. (And you should have a recent version, of course, because older versions are not secure.)

  • Don't the src.rpm files qualify as source code? Download the src.rpm file and rpm2cpio texlive-dummy-2012a-1.el7.src.rpm | cpio -div '*.spec' to get the spec file the rpm is using. – Jos Jun 8 '16 at 13:07
  • By the way, I'm not using Fedora but CentOS, which works fine with yum – Jos Jun 8 '16 at 13:30
  • @Jos Oh, right. Yes, sorry - I missed that. CentOS uses older stuff, so you won't have dnf yet. – cfr Jun 8 '16 at 15:44
1

As daleif suggested, the package is on CTAN. It's called "texlive-dummy" (at least for RedHat-based distributions), and works like a charm.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.