Skip to content

Commit 46573e6

Browse files
committed
Add script to build documentation on win32 without mingw
1 parent 02284e2 commit 46573e6

File tree

2 files changed

+63
-0
lines changed

2 files changed

+63
-0
lines changed

src/tools/msvc/Solution.pm

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -229,6 +229,13 @@ EOF
229229
last;
230230
}
231231
}
232+
233+
open(O, ">doc/src/sgml/version.sgml") || croak "Could not write to version.sgml\n";
234+
print O <<EOF;
235+
<!entity version "$self->{strver}">
236+
<!entity majorversion "$self->{majorver}">
237+
EOF
238+
close(O);
232239
}
233240

234241
sub AddProject {

src/tools/msvc/builddoc.bat

Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
@echo off
2+
REM Adjust path for your docbook installation
3+
SET ROOT=c:\prog\pgsql\docbook
4+
5+
SETLOCAL
6+
SET STARTDIR=%CD%
7+
SET OPENJADE=openjade-1.3.1
8+
SET DSSSL=docbook-dsssl-1.79
9+
10+
IF EXIST ..\msvc IF EXIST ..\..\..\src cd ..\..\..
11+
IF NOT EXIST doc\src\sgml\version.sgml goto noversion
12+
13+
IF NOT EXIST %ROOT%\%OPENJADE% SET NF=OpenJade
14+
IF NOT EXIST %ROOT%\docbook SET NF=docbook
15+
IF NOT EXIST %ROOT%\%DSSSL% set NF=docbook-dssl
16+
17+
IF NOT "%NF%" == "" GOTO notfound
18+
19+
IF "%1" == "renamefiles" GOTO renamefiles
20+
21+
cmd /v /c "%0" renamefiles
22+
23+
cd doc\src\sgml
24+
25+
SET SGML_CATALOG_FILES=%ROOT%\%OPENJADE%\dsssl\catalog;%ROOT%\docbook\docbook.cat
26+
perl %ROOT%\%DSSSL%\bin\collateindex.pl -f -g -o bookindex.sgml -N
27+
perl mk_feature_tables.pl YES ..\..\..\src\backend\catalog\sql_feature_packages.txt ..\..\..\src\backend\catalog\sql_features.txt > features-supported.sgml
28+
perl mk_feature_tables.pl NO ..\..\..\src\backend\catalog\sql_feature_packages.txt ..\..\..\src\backend\catalog\sql_features.txt > features-unsupported.sgml
29+
30+
%ROOT%\%OPENJADE%\bin\openjade -V draft-mode -wall -wno-unused-param -wno-empty -D . -c %ROOT%\%DSSSL%\catalog -d stylesheet.dsl -i output-html -t sgml postgres.sgml
31+
perl %ROOT%\%DSSSL%\bin\collateindex.pl -f -g -i 'bookindex' -o bookindex.sgml HTML.index
32+
%ROOT%\%OPENJADE%\bin\openjade -V draft-mode -wall -wno-unused-param -wno-empty -D . -c %ROOT%\%DSSSL%\catalog -d stylesheet.dsl -i output-html -t sgml postgres.sgml
33+
34+
cd %STARTDIR%
35+
echo Docs build complete.
36+
exit /b
37+
38+
39+
:renamefiles
40+
REM Rename ISO entity files
41+
CD %ROOT%\docbook
42+
FOR %%f in (ISO*) do (
43+
set foo=%%f
44+
IF NOT "!foo:~-4!" == ".gml" ren !foo! !foo:~0,3!-!foo:~3!.gml
45+
)
46+
exit /b
47+
48+
:notfound
49+
echo Could not find directory for %NF%.
50+
cd %STARTDIR%
51+
goto :eof
52+
53+
:noversion
54+
echo Could not find version.sgml. Please run mkvcbuild.pl first!
55+
cd %STARTDIR%
56+
goto :eof

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy