.dtx are source files, they are usually sorted into the
source subtree of a TDS tree (
The files in a TDS tree are organized in such a way, that source, documentation files are not searched, when TeX looks for its input/package/class files. This reduces the search space and makes file look-up faster.
But on the other side, it is not possible to call generate source files from somewhere else, because
.dtx files are not found outside of the sub tree
these files can be compiled in the directory, where they are:
However, this will not work in MiKTeX because of a security feature.
See Ulrike's answer (MiKTeX does not find files in application directories).
Copy the files to a fresh scratch directory and compile there:
copy source\latex\babel/* scratch
(The path before
source\... is omitted in both examples and needs to be added.)
Usually LaTeX installation files
.ins can be run by plain TeX (
tex), because the
.ins files are based on
docstrip, which does not need the LaTeX format. In some cases, LaTeX is needed nevertheless, sometimes only because of some silly
Typically a LaTeX user do not need to run
.ins files, because the TeX distribution provides the packages unpacked already. If the TeX distribution does not contains the package, then CTAN might have
package.tds.zip files below
CTAN:install/. They only need to be unpacked at the root of the TDS tree (plus refreshing the file name database).
Problem (c) "Command not found", discussed in the comment section
MiKTeX portable does not add its directory
bin to the environment variable
PATH. Therefore Windows is not able to find the binaries, if they are not qualified with a sufficient path component. This is the price of being portable. The host system remains untouched and the path of the
bin folder can change (different USB drive letters, ...).
In order to use MiKTeX portable with a command window,
miktex-portable in the installation directory of MiKTeX portable should be called first. It adds an icon to the task bar. A right click offers the option "Command Prompt", which opens a command window, where the environment variables for MiKTeX are set. See "How to use MiKTeX portable".
If you want to use MiKTeX on your system permanently, then the normal MiKTeX version is preferable. Otherwise, the environment variables can be configures manually in the Windows system, if the
bin folder has a permanent location or the previously described way can be used.