You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In #9003 the MKIDX_CMD setting was introduced to align the approach with LATEX_CMD and also to give on *nix the possibility to define these commands outside the Makefile.
In this patch:
- add the missing setting for bibtex
- add the missing setting for the number of reruns (giving more flexibility) overules #250
- add setting for the name of the manual
- make the overrule possibility also available under Windows
- add rerun test on bibliographical references
if (!Config_getBool(USE_PDFLATEX)) // use plain old latex
398
417
{
399
-
t << "set LATEX_CMD=" << latex_command << "\r\n";
400
-
t << "set MKIDX_CMD=" << mkidx_command << "\r\n";
401
-
t << "%LATEX_CMD% refman.tex\r\n";
418
+
t << "%LATEX_CMD% %MANUAL_FILE%.tex\r\n";
402
419
t << "echo ----\r\n";
403
-
t << "%MKIDX_CMD% refman.idx\r\n";
420
+
t << "%MKIDX_CMD% %MANUAL_FILE%.idx\r\n";
404
421
if (generateBib)
405
422
{
406
-
t << "bibtex refman\r\n";
423
+
t << "%BIBTEX_CMD% %MANUAL_FILE%\r\n";
407
424
t << "echo ----\r\n";
408
-
t << "\t%LATEX_CMD% refman.tex\r\n";
425
+
t << "\t%LATEX_CMD% %MANUAL_FILE%.tex\r\n";
409
426
}
410
427
t << "setlocal enabledelayedexpansion\r\n";
411
-
t << "set count=8\r\n";
428
+
t << "set count=%LAT#EX_COUNT%\r\n";
412
429
t << ":repeat\r\n";
413
430
t << "set content=X\r\n";
414
-
t << "for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun LaTeX\" refman.log' ) do set content=\"%%~T\"\r\n";
415
-
t << "if !content! == X for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun to get cross-references right\" refman.log' ) do set content=\"%%~T\"\r\n";
431
+
t << "for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun LaTeX\" %MANUAL_FILE%.log' ) do set content=\"%%~T\"\r\n";
432
+
t << "if !content! == X for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun to get cross-references right\" %MANUAL_FILE%.log' ) do set content=\"%%~T\"\r\n";
433
+
t << "if !content! == X for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun to get bibliographical references right\" %MANUAL_FILE%.log' ) do set content=\"%%~T\"\r\n";
416
434
t << "if !content! == X goto :skip\r\n";
417
435
t << "set /a count-=1\r\n";
418
436
t << "if !count! EQU 0 goto :skip\r\n\r\n";
419
437
t << "echo ----\r\n";
420
-
t << "%LATEX_CMD% refman.tex\r\n";
438
+
t << "%LATEX_CMD% %MANUAL_FILE%.tex\r\n";
421
439
t << "goto :repeat\r\n";
422
440
t << ":skip\r\n";
423
441
t << "endlocal\r\n";
424
-
t << "%MKIDX_CMD% refman.idx\r\n";
425
-
t << "%LATEX_CMD% refman.tex\r\n";
426
-
t << "dvips -o refman.ps refman.dvi\r\n";
442
+
t << "%MKIDX_CMD% %MANUAL_FILE%.idx\r\n";
443
+
t << "%LATEX_CMD% %MANUAL_FILE%.tex\r\n";
444
+
t << "dvips -o %MANUAL_FILE%.ps %MANUAL_FILE%.dvi\r\n";
427
445
t << Portable::ghostScriptCommand();
428
446
t << " -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite "
429
-
"-sOutputFile=refman.pdf -c save pop -f refman.ps\r\n";
447
+
"-sOutputFile=%MANUAL_FILE%.pdf -c save pop -f %MANUAL_FILE%.ps\r\n";
430
448
}
431
449
else// use pdflatex
432
450
{
433
-
t << "set LATEX_CMD=" << latex_command << "\r\n";
434
-
t << "set MKIDX_CMD=" << mkidx_command << "\r\n";
435
-
t << "%LATEX_CMD% refman\r\n";
451
+
t << "%LATEX_CMD% %MANUAL_FILE%\r\n";
436
452
t << "echo ----\r\n";
437
-
t << "%MKIDX_CMD% refman.idx\r\n";
453
+
t << "%MKIDX_CMD% %MANUAL_FILE%.idx\r\n";
438
454
if (generateBib)
439
455
{
440
-
t << "bibtex refman\r\n";
441
-
t << "%LATEX_CMD% refman\r\n";
456
+
t << "%BIBTEX_CMD% %MANUAL_FILE%\r\n";
457
+
t << "%LATEX_CMD% %MANUAL_FILE%\r\n";
442
458
}
443
459
t << "echo ----\r\n";
444
-
t << "%LATEX_CMD% refman\r\n\r\n";
460
+
t << "%LATEX_CMD% %MANUAL_FILE%\r\n\r\n";
445
461
t << "setlocal enabledelayedexpansion\r\n";
446
-
t << "set count=8\r\n";
462
+
t << "set count=%LATEX_COUNT%\r\n";
447
463
t << ":repeat\r\n";
448
464
t << "set content=X\r\n";
449
-
t << "for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun LaTeX\" refman.log' ) do set content=\"%%~T\"\r\n";
450
-
t << "if !content! == X for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun to get cross-references right\" refman.log' ) do set content=\"%%~T\"\r\n";
465
+
t << "for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun LaTeX\" %MANUAL_FILE%.log' ) do set content=\"%%~T\"\r\n";
466
+
t << "if !content! == X for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun to get cross-references right\" %MANUAL_FILE%.log' ) do set content=\"%%~T\"\r\n";
467
+
t << "if !content! == X for /F \"tokens=*\" %%T in ( 'findstr /C:\"Rerun to get bibliographical references right\" %MANUAL_FILE%.log' ) do set content=\"%%~T\"\r\n";
0 commit comments