Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 71038 - new ebuild: CM-Super is collection of Type 1 fonst converted from METAFONT fonts and covers entire EC/TC, EC Concret
Summary: new ebuild: CM-Super is collection of Type 1 fonst converted from METAFONT fo...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: New packages (show other bugs)
Hardware: All Linux
: Normal enhancement
Assignee: Gentoo Fonts Team
URL:
Whiteboard:
Keywords: EBUILD
: 78686 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-11-13 00:09 UTC by Andrey Ulanov
Modified: 2008-11-18 08:14 UTC (History)
9 users (show)

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


Attachments
cm-super-0.3.3.ebuild (cm-super-0.3.3.ebuild,1.61 KB, text/plain)
2004-11-13 00:09 UTC, Andrey Ulanov
Details
cm-super-0.3.3.ebuild (cm-super-0.3.3.ebuild,1.49 KB, text/plain)
2004-11-13 00:17 UTC, Andrey Ulanov
Details
cm-super-0.3.3.ebuild (cm-super-0.3.3.ebuild,1.20 KB, text/plain)
2004-11-13 13:01 UTC, Andrey Ulanov
Details
cm-super-0.3.3.ebuild (cm-super-0.3.3.ebuild,1.37 KB, text/plain)
2005-04-28 04:46 UTC, Tobias Hahn
Details
Patch for cm-super-0.3.3.ebuild from Tobias Hahn (cm-super-0.3.3.ebuild.patch,1.20 KB, patch)
2005-12-12 01:08 UTC, Mathias Weigt
Details | Diff
new cm-super ebuild (cm-super-0.3.3.ebuild,1.52 KB, text/plain)
2006-01-05 07:43 UTC, Andreas Volz
Details
new ebuild for cm-super-0.3.3 (cm-super-0.3.3.ebuild,1.52 KB, text/plain)
2006-01-05 07:49 UTC, Andreas Volz
Details
fixed my last ebuild (cm-super-0.3.3.ebuild,1.49 KB, text/plain)
2006-01-06 02:01 UTC, Andreas Volz
Details
fixed the last ebuild (cm-super-0.3.3.ebuild,1.58 KB, text/plain)
2006-01-27 06:41 UTC, Mathias Weigt
Details
replaced "enc" sed call with "map" (cm-super-0.3.3.ebuild,1.58 KB, text/plain)
2006-01-27 08:54 UTC, Andreas Volz
Details
cm-super-0.3.3.ebuild based on latex-package.eclass (cm-super-0.3.3.ebuild,1.68 KB, text/plain)
2006-03-04 11:03 UTC, Martin von Gagern
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Andrey Ulanov 2004-11-13 00:09:23 UTC
This package is intended to be used with teTeX. 

Reproducible: Always
Steps to Reproduce:
Comment 1 Andrey Ulanov 2004-11-13 00:09:56 UTC
Created attachment 43845 [details]
cm-super-0.3.3.ebuild
Comment 2 Andrey Ulanov 2004-11-13 00:17:39 UTC
Created attachment 43846 [details]
cm-super-0.3.3.ebuild

corrected
Comment 3 Carsten Lohrke (RETIRED) gentoo-dev 2004-11-13 06:41:31 UTC
Andrey, your ebuild has a couple of issues:
1. The header is invalid
http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&chap=3
2. A dev is only allowed to add the Keywords, he can test. Even though its "only" a fonts package, adding all possible keywords isn't needed or wanted.
3.The ebuild uses sed, so it's a DEPEND
4. The appropriate unpack functions need to be called. Just e.g. tar ... is not correct.
5. using a herefile is a bit ugly
Comment 4 Andrey Ulanov 2004-11-13 13:01:04 UTC
> Andrey, your ebuild has a couple of issues:
> 1. The header is invalid
> http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2&chap=3

Freankly speaking I do not quiet understand meaning of this requirement. CVS understands $Header$ (without colon) just well.

> 2. A dev is only allowed to add the Keywords, he can test. Even though its 
> "only" a fonts package, adding all possible keywords isn't needed or wanted.

Not a big problem too. The one who who will commit my ebuild can correct is as he want.

> 3.The ebuild uses sed, so it's a DEPEND
> 4. The appropriate unpack functions need to be called. Just e.g. tar ... is 
> not correct.
> 5. using a herefile is a bit ugly

OK. I tryed to comply with these requirements. Hope it is little better now.
Comment 5 Andrey Ulanov 2004-11-13 13:01:46 UTC
Created attachment 43878 [details]
cm-super-0.3.3.ebuild
Comment 6 Mamoru KOMACHI (RETIRED) gentoo-dev 2004-11-13 21:24:50 UTC
Andrey, as for ebuild header, what you didn't
follow is not $Header$ but Gentoo Technologies, Inc.
Gentoo Technologies, Inc. is drobbins' company
and Gentoo Foundation is the entity who
runs Gentoo Project. Please use Gentoo Foundation
instead of Gentoo Technologies, Inc.

Also, the reason we ask ebuild submitters to 
rewrite their ebuilds is because
we'd like to tell them the way we write ebuilds.
(Yes, we can correct your ebuild when we commit,
but if we do so you may or may not notice adding
non-tested arches is not allowed by our policy)
Comment 7 Sune Foldager 2005-02-06 12:28:58 UTC
*** Bug 78686 has been marked as a duplicate of this bug. ***
Comment 8 Sune Foldager 2005-02-06 12:34:21 UTC
Alright, I for some reason didn't spot this package when I made a similar one (bug 78686). The
differences between this and mine:

1. I couldn't locate the updmap.cfg file -- I looked where the cm-super distro told me for teTeX and it obviously wasn't there. Oh well :-p.. so I went for the hard way, patching the three config files for pdftex, dvips and dvpdfm respectively. This way of doing it (the present bug) is of course better.

2. I pull a souce directly, and thus don't depend on rpg2tbz. I recomend we do the same here, since it's kind of a weird dependency IMO.
Comment 9 Tobias Hahn 2005-04-28 04:46:49 UTC
Created attachment 57465 [details]
cm-super-0.3.3.ebuild

As I desparately need this package and there has not been any activity on this
bug for quite a while, I adapted the best ideas from the existing two
suggestions and wrote my own ebuild. If this is against netiquette, please
ignore this attachment.

Changes against Andreys ebuild:
- Header conforms to Gentoo requirements.
- HOMEPAGE changed to CTAN-home
- SRC_URI changed to CTAN-download, providing .tar.gz instead of .rpm
- new function src_unpack() to circumvent a problem with the .tar.gz. The
tar.gz at CTAN is generated automatically using a broken/misconfigured tar. The
archive contains "trailing garbage", which gzip warns about, but which is
harmless otherwise. See the gzip manpage for details. The default src_unpack
dies due to this warning. For this reason, I pass "-f" (force) to gzip. This
way, it exits cleanly. If Gentoo repacks the .tar.gz (using gunzip tar -x tar
-c gzip), this function is obsolete.
- src_install() prints a warning if installation of the docs fails and dies if
the installation of fonts or the fontmaps fails.

Enjoy!
Comment 10 Mathias Weigt 2005-12-12 01:08:34 UTC
Created attachment 74561 [details, diff]
Patch for cm-super-0.3.3.ebuild from Tobias Hahn

I tried Tobias ebuild and there were some issues:
1. CTAN seems not providing tar file any more - so I switched to zip.
2. type1ec.sty is not installed into LaTeX path - I added it.
Comment 11 Andreas Volz 2006-01-05 07:43:43 UTC
Created attachment 76242 [details]
new cm-super ebuild

The last cm-super ebuild doesn't work on my system. So I chanched the ebuild to work on my system. I hope all changes are good. What I changed:

- path for *.map and *.enc files
  read this: http://tug.org/texlive/mapenc.html

- adjusted path for pkg_postint() and pkg_postrm()

- use /var/lib/texmf/web2c/updmap.cfg to work correct

- changed updmap to updmap-sys for global use

- added mktexlsr (not sure if this is really needed)

Be sure to remove the old ebuild before installing this ebuild, because the pkg_postint() and pkg_postrm() are changed

regards
Andreas
Comment 12 Andreas Volz 2006-01-05 07:49:17 UTC
Created attachment 76243 [details]
new ebuild for cm-super-0.3.3

The last cm-super ebuild doesn't work on my system. So I chanched the ebuild to work on my system. I hope all changes are good. What I changed:

- path for *.map and *.enc files
  read this: http://tug.org/texlive/mapenc.html

- adjusted path for pkg_postint() and pkg_postrm()

- use /var/lib/texmf/web2c/updmap.cfg to work correct

- changed updmap to updmap-sys for global use

- added mktexlsr (not sure if this is really needed)

Be sure to unmerge the old ebuild before merging this ebuild, because the pkg_postint() and pkg_postrm() are changed
Comment 13 Tobias Hahn 2006-01-05 08:33:42 UTC
Just had a quick look at your ebuild, apparently Mathias forgot to remove my comment ('# Pass option -f to gzip to avoid dying due to "trailing garbage".') about the force option to gzip when changing from tar.gz to zip. Would you do that? Thx!
Comment 14 Andreas Volz 2006-01-06 02:01:38 UTC
Created attachment 76311 [details]
fixed my last ebuild

Fixed a big bug from the last ebuild! Don't use my last ebuild. It overwrites the link in /var/lib/texmf/web2c/updmap.cfg to /etc/texmf/web2c/updmap.cfg. If you've installed the last ebuild then recreate this link!

Now I insert the Maps in /etc/texmf/updmap.d/00updmap.cfg to stay also if a latex update is done.

And the ebuild runs now some more latex update script to get all data updated. Not sure if all are needed, but they don't hurt.

BTW: For which tetex did you build the cm-super packages in past? I've installed tetex-3.0-r2. Should I set this somewhere in ebuild options? I think the paths in tetex-2.x are a little different? What is the policy for such problems? Should we only support the latest tetex version?
Comment 15 Tobias Hahn 2006-01-06 02:25:01 UTC
I'm using the latest stable, i.e. 2.0.2-r5.
Comment 16 Andreas Volz 2006-01-06 02:40:50 UTC
Oh, then you should be careful if installing my ebuilds! How do I correct define to use tetex-3.0-r2? Currently it's this:

RDEPEND="virtual/tetex"
DEPEND="${RDEPEND}
        sys-apps/sed
    app-arch/unzip"

Do you like to test the ebuild with the 2.x version? If not we should maintain two different versions of cm-super. Or should this be done with if/else stuff inside to ebuild for each tetex version?
Comment 17 Tobias Hahn 2006-01-06 04:57:32 UTC
Sorry, I don't have the time to test stuff right now. 

For dependencies: Right now, there seems to be no way to depend on specific versions of virtuals (see http://www.gentoo.org/proj/en/glep/glep-0037.html). So one way would be to change the dependency to 

DEPEND=">=app-text/tetex-3"

Probably a better way is to see what version is installed. The latex-package.eclass exports the function has_tetex_3() that returns true if tetex-3 or ptex-3.1.8 or higher is installed.

The optimal way probably would be to use the functionality of the eclass. It provides functionality to install fonts, do the rehashing after installation etc. It is well documented  file:///usr/portage/eclass/latex-package.eclass 
maybe this will help :)

Any volunteers?
Comment 18 Mathias Weigt 2006-01-20 03:25:18 UTC
(In reply to comment #14)
> Fixed a big bug from the last ebuild! Don't use my last ebuild. It overwrites
> the link in /var/lib/texmf/web2c/updmap.cfg to /etc/texmf/web2c/updmap.cfg. 

Sorry I have problems with this ebuild here with a system using tetex-3.0-r4. I get this error-message from the call of updmap-sys:

!!! ERROR! The map file `cm-super-t1.map' has not been found at all.

    Either put this file into the right place or remove the
    reference from the configuration file. An automatic way
    to disable unavailable map files is to call
      updmap --syncwithtrees

    For manual editing, call
      updmap --edit
-------
I don't know, why the maps are not found, they are in /usr/share/texmf/fonts/enc/dvips/cm-super/

Mathias
Comment 19 Mathias Weigt 2006-01-27 06:39:21 UTC
> Sorry I have problems with this ebuild here with a system using tetex-3.0-r4. > I get this error-message from the call of updmap-sys:
> 
> !!! ERROR! The map file `cm-super-t1.map' has not been found at all.
> 
>     Either put this file into the right place or remove the
>     reference from the configuration file. An automatic way
>     to disable unavailable map files is to call
>       updmap --syncwithtrees
> 
>     For manual editing, call
>       updmap --edit
> -------
> I don't know, why the maps are not found, they are in
> /usr/share/texmf/fonts/enc/dvips/cm-super/

The reason is: The map files were installed into the "enc"-Directory, they should go into the "map" directory. I submit the fixed ebuild
Comment 20 Mathias Weigt 2006-01-27 06:41:32 UTC
Created attachment 78284 [details]
fixed the last ebuild

The map files were installed into the "enc"-Directory, they
should go into the "map" directory.
Comment 21 Andreas Volz 2006-01-27 08:54:48 UTC
Created attachment 78289 [details]
replaced "enc" sed call with "map"

Ok, I tested the last ebuild. You're right with the map files. But if you change the place for the map files the pkg_postinst() function need to be changed also. I did this and here is the new ebuild file. I hope it works for you. :-)
Comment 22 Mathias Weigt 2006-02-13 11:31:38 UTC
(In reply to comment #21)
> Created an attachment (id=78289) [edit]
> replaced "enc" sed call with "map"
> 
> Ok, I tested the last ebuild. You're right with the map files. But if you
> change the place for the map files the pkg_postinst() function need to be
> changed also. I did this and here is the new ebuild file. I hope it works for
> you. :-)
> 

it works good for me (tested on three different machines)
Comment 23 Martin von Gagern 2006-03-04 11:02:17 UTC
(In reply to comment #17)
> The optimal way probably would be to use the functionality of the eclass. It
> provides functionality to install fonts, do the rehashing after installation
> etc. Any volunteers?

I rewrote the ebuild with this in mind. There are several changes:
1. introduced USE flag to optionally install afm files
2. correctly set source dir ${S}=${WORKDIR}/${PN}
3. generation of updmap configuration in src_compile, not pkg_postinst
4. installation of pfb, afm and sty using latex-package.eclass
5. installing updmap into a seperate file
6. pkg_postinst and pkg_postrm inherited from latex-package.eclass

The procedure from 5. pevents any tweaking with 00updmap. Instead you simply create your own file, and texmf-update combines all files in this directory to the final configuration file used by tetex. If the directory /etc/texmf/updmap.d/ was included in CONFIG_PROTECT_MASK as it imho should be, the file would automatically be unmerged with the package. I filed the seperate bug #124986 about this issue.

6. works because in latex-package.eclass the default implementation already calls latex-package_rehash, which in turn calls texmf-update, which in turn calls both mktexlsr, texconfig-sys and updmap-sys.
Comment 24 Martin von Gagern 2006-03-04 11:03:47 UTC
Created attachment 81327 [details]
cm-super-0.3.3.ebuild based on latex-package.eclass
Comment 25 foser (RETIRED) gentoo-dev 2006-03-04 11:13:20 UTC
If these are a set of Type 1 fonts, then the ebuild should use the font eclass and the default location for fonts in gentoo /usr/share/fonts .

Not sure what is needed for tex to be able to pick up these fonts, adding the respective herd to shed some light on that.
Comment 26 Alexandre Buisse (RETIRED) gentoo-dev 2006-03-04 12:11:36 UTC
I'm no tex font expert, but I think that to find them, TeX needs to have them in one of its ${TEXMF}/fonts/whatever directory, and then call latex-package_rehash which will call the right functions (see comment #23).
Comment 27 Christof Schulze 2006-05-30 15:57:25 UTC
is there any chance this will be in portage some time soon?
I wanna try it out...
Comment 28 Tobias Hahn 2006-05-31 00:34:09 UTC
(In reply to comment #27)
> is there any chance this will be in portage some time soon?
> I wanna try it out...

I have no idea if/when this is going to be in portage, but trying it out should be easy. The last version of the ebuild depends on tetex-3, which is testing right now. 

This is experimental stuff and there is a slight chance that these instructions might break your system, fry your cpu and cause your partner to cheat on you. It is your responsability if you proceed, so don't blame me!
 
If you want to stick to stable tetex-2 but need to have cm-super, you can download attachment 57465 [details] from 2005-04-28 in step 3 instead. This should not update an existing tetex-2 installation, but still be sure to check the output of emerge -av.

1. Add the following line to your /etc/make.conf

PORTDIR_OVERLAY="/usr/local/portage"

2. Create the directory /usr/local/portage/dev-tex/cm-super
3. Download the latest attachment (right now attachment 81327 [details] from 2006-03-04) to this directory.
3a. If you are _not_ on x86, you need to 

# ekeyword "~your-arch" /usr/local/portage/dev-tex/cm-super/cm-super-0.3.3.ebuild

4. Enter the command

# ebuild /usr/local/portage/dev-tex/cm-super/cm-super-0.3.3.ebuild digest

This should download the fonts and create Manifest and Digest.

WARNING: The following will update your tetex incl. dependencies to tetex-3 using unstable (~x86) packages, so carefully check the output of emerge -av before proceeding.

5. Do it. Of course, if you are not on x86, you need to replace '~x86' with '~your-arch'

# ACCEPT_KEYWORDS="~x86" emerge -av cm-super

6. Read chapter 5 and 6 of http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=3 to understand what you just did. Read chapter 1 of http://www.gentoo.org/proj/en/devrel/handbook/handbook.xml?part=2 to learn more
about ebuilds.
Comment 29 Peter Gustafson 2007-02-13 18:18:45 UTC
Just a report that this built fine on my amd64 machine.  Seemingly no problems after a few hours of use.
Comment 30 Emiliano Vavassori 2007-02-25 16:58:49 UTC
(In reply to comment #25)
> If these are a set of Type 1 fonts, then the ebuild should use the font eclass
> and the default location for fonts in gentoo /usr/share/fonts .

Well, yes; but I consider what you have just said as a 'hack' on the package, since these fonts are designed for the use with TeX and not with X. Also, it's a big package (nearly 60 MB), which you want only in the case you're writing with TeX to make sure your documents will use vector-drawn glyphs.

Nonetheless, your idea may be good; let someone which doesn't know what TeX is install these fonts for X usage and, using for example a useflag 'tex', let another informed user use them in his documents. Also, in the case of '-tex', some files from the distribution may be left out of the installation process.

> Not sure what is needed for tex to be able to pick up these fonts, adding the
> respective herd to shed some light on that.

I suggest that the ebuild will do a symlink between /usr/share/fonts/Type1/CM-super and /usr/share/texmf-site/fonts/type1/CM-super,
install the .map files in /usr/share/texmf-site/fonts/map/dvips/CM-super, inserting a 10cmsuper.cfg file in /etc/texmf/updmap.d allowing the use of these fonts in tetex and do a texmf-update.

If it does interest you all, please let me know and I'll work on it.
Comment 31 Faustus 2007-07-21 10:19:29 UTC
Hi,

Maybe it's time to add cm-super to portage?
Comment 32 Martin von Gagern 2007-12-15 15:45:06 UTC
FYI: According to bug 137197, tetex should one day be replaced by texlive. A quick grep over the ebuilds tells me that texlive-fontsextra includes cm-super, among several others. So an alternative to installing one of the attached ebuilds would be to switch over to texlive and use dev-texlive/texlive-fontsextra.
Comment 33 Denis Pesotsky 2008-11-17 20:19:41 UTC
Time to close bug! It's in dev-texlive/texlive-fontsextra already.
Comment 34 Peter Volkov (RETIRED) gentoo-dev 2008-11-18 08:14:39 UTC
Yup, it look like this bug is already fixed.