1

Possible Duplicate:
How can I manually install a package on MiKTeX (Windows)

I am writing this because I need a more efficient way to use the acmsmall class. The problem is when I add the .cls and .bst files within my folder everything works just fine, but when I remove them from the folder the message acmsmall.cls not found appears.

Is there a way to add the class into my MiKTeX or TeXnicCenter?

Amait
  • 187
  • 2
    Put them in a folder in C:\Program Files\MikTex <versionnumber>\tex\latex\<youchoosename> and then run Refresh FNDB from MikTeX package manager (admin) – cmhughes May 09 '12 at 13:32
  • @cmhughes : for any name or the class name? I'm new to this. – Amait May 10 '12 at 20:02
  • @Stephen: understood – Amait May 10 '12 at 20:02
  • 1
    from MiKTeX's point of view it doesn't matter- it would perhaps make sense from your point of view to use the class name for future reference :) – cmhughes May 10 '12 at 20:03
  • did this fix the problem? if so, I'll convert my comments to an answer... – cmhughes May 11 '12 at 09:46
  • please, yeah it worked ^^ – Amait May 11 '12 at 15:28
  • @cmhughes Please, convert your comment to an answer. Probably you were not notified about the last OP's comment. – egreg Jun 02 '12 at 22:13
  • @egreg thanks for the ping- you were (of course) correct, I wasn't notified. I also wonder if this question should be closed as too localized?... – cmhughes Jun 02 '12 at 22:59
  • 3
    This looks very much like http://tex.stackexchange.com/questions/2063/how-can-i-manually-install-a-package-on-miktex-windows to me – Joseph Wright Jun 03 '12 at 08:15
  • @cmhughes: It is better to manually install packages/classes into an own local TEXMF, which in MiKTeX first must be defined. The problem is, when in far, far future the OP installs a new version of MiKTeX, his/her own package/class install will vanish, and surely he/she will not know anymore why. But the directory with the local TDS can again be included. – Speravir Jun 04 '12 at 00:40
  • @JosephWright: But see my answer to cmhughes. – Speravir Jun 04 '12 at 00:42
  • @Speravir thanks for the clarification. Perhaps you can write an answer? – cmhughes Jun 04 '12 at 01:11
  • 1
    @Speravir What I was getting at is that there is a general 'install a package manually with MiKTeX' answer. You'll see there that I've asked Stefan to update the answer to avoid installing in the MiKTeX-managed tree, and to recommend instead a 'local' folder. – Joseph Wright Jun 04 '12 at 07:41

1 Answers1

1

Update

Meanwhile there are for all, what was written below, own, more elaborate answers:


Original answer

First: It has nothing to do with TeXnicCenter, the TeX editor is not involved in such problems.

As I already wrote in my comment, every manually installed package and also configuration files should always go into a local TeXMF directory, because otherwise on an update all data will safely be lost!

In an Texlive installation there exists by default at least one local directory: texmf-local. But in MiKTeX you have to create your own folder first (all the following for a one-user-installation):

  1. Create somewhere on your computer a folder – with an important exception. It must not be a subfolder of your MiKTeX installation (it worked this way in older MiKTeX versions, but was changed for security reasons). I will use here c:\localtexmf.

    This folder must be TDS compliant (for that see A Directory Structure for TeX Files); MiKTeX will complain, if not. At least a tex\latex subtree should be sufficient. But in your case we need more: The ZIP files provided by ACM are not at all in a TDS compatible strucure. So we have to do it ourselves, we will mimic the structure of the (itself TDS compliant) MiKTEX tree.

  2. All files will be put in several subfolders, that should get a meaningful name, as cmhughes already pointed out. I would suggest acmclasses (BTW in a full MiKTeX installation there is already a class acmconf, that does not seem to be official.)

    • All BST files go into c:\localtexmf\bibtex\bst\acmclasses.
    • The CLS files (which are the class defining ones) go to c:\localtexmf\tex\latex\acmclasses.
    • algorithm2e.sty is not needed, you should not extract it! The package algorithm2e is part of MiKTeX distribution and can therefore be installed and updated with MiKTeX’ own tools, see How do I update my TeX distribution – MiKTeX GUI or, if you prefer that, How do I update my TeX distribution – MiKTeX from the Command line.
    • All other files are documentation and example files, and go to c:\localtexmf\doc\latex\acmclasses\. The readme.txt files should of course be renamed first, e.g. to acm-<large/small/tog>-readme.txt, the guide.pdf of acm-tog should also get a unique name. All example files could go into an additional subfolder c:\localtexmf\doc\latex\acmclasses\examples as well.
    • In general: Other manual installations nedd to install fonts or scripts. Then they have to be installed into the localtexmf equivalent under fonts\… or scripts\….
  3. In the Start Menu go to the MiKTeX entry and open the settings. The “MiKTeX Options” window will open.

  4. Go there to the “Roots” tab. Click on “Add” and choose c:\localtexmf\. If there are more than one local directory, one can choose the search order with the “Up” and “Down” buttons.

  5. Now the almost most important part: Go to the “General” tab and click there on “Refresh FNDB” (FNDB = File Name Data Base). In some cases, especially if new fonts are installed, one has also to press the “Update Formats” button.

    If you’d forget this step, all earlier steps would be done to no purpose.

(I’ve already described it for MiKTEX-portable: Using MikTex Portable, TexMaker, and Asymptote from a USB drive.)

Speravir
  • 19,491