hmemcpy / milewski-ctfp-pdf

Bartosz Milewski's 'Category Theory for Programmers' unofficial PDF and LaTeX source
https://bartoszmilewski.com/2014/10/28/category-theory-for-programmers-the-preface/
Other
10.84k stars 575 forks source link

Cannot build #283

Closed Lunuy closed 2 years ago

Lunuy commented 2 years ago

Cannot build in windows. (Nix on WSL2 Ubuntu) ctfp.log

Error: cannot read infile: [Errno 2] No such file or directory: 'ctfp.pyg'
system returned with code 256

! Package minted Error: Missing Pygments output; \inputminted was
probably given a file that does not exist--otherwise, you may need
the outputdir package option, or may be using an incompatible build tool,
or may be using frozencache with a missing file.

See the minted package documentation for explanation.
Type  H <return>  for immediate help.
 ...
l.72 S
      imilarly:
Output written on ctfp.pdf (11 pages).
Transcript written on ctfp.log.
=== TeX engine is 'XeTeX'
Latexmk: Index file 'ctfp.idx' was written
Latexmk: Log file says output to 'ctfp.pdf'
Latexmk: List of undefined refs and citations:
  Reference `mdf@pagelabel-1' on page 4 undefined on input line 38
  Reference `mdf@pagelabel-2' on page 4 undefined on input line 49
  Reference `mdf@pagelabel-3' on page 4 undefined on input line 54
  Reference `mdf@pagelabel-4' on page 4 undefined on input line 62
Latexmk: Summary of warnings from last run of (pdf)latex:
  Latex failed to resolve 4 reference(s)
Latexmk: Errors, so I did not complete making targets
Collected error summary (may duplicate other messages):
  pdflatex: Command for 'pdflatex' gave return code 1
      Refer to 'ctfp.log' for details
Latexmk: Use the -f option to force complete processing,
 unless error was exceeding maximum runs, or warnings treated as errors.
drupol commented 2 years ago

Going to give it a try,

Could you please tell me more? What are the commands you're running?

Lunuy commented 2 years ago

I installed Nix using this command:

sh <(curl -L https://nixos.org/nix/install) --no-daemon

Then treid to build pdf:

nix-shell
cd src
make

The log logged when I run make command.

drupol commented 2 years ago

Right, I'm currently installing the project using nix flakes with:

nix shell

It will take some times, I will give you some feedback once it's done.

In the meantime, could you please enable Flakes on Nix? (https://nixos.wiki/wiki/Flakes) And retry with the command (hence the missing dash):

nix shell

Thanks.

drupol commented 2 years ago

I succeeded to build using Nix, by doing:

nix build .

Once it's done, you'll find the PDFs in ./result/ directory in the project root.

Lunuy commented 2 years ago

Thanks, it works.