@ECHO OFF REM Licensed to the Apache Software Foundation (ASF) under one or more REM contributor license agreements. See the NOTICE file distributed with REM this work for additional information regarding copyright ownership. REM The ASF licenses this file to You under the Apache License, Version 2.0 REM (the "License"); you may not use this file except in compliance with REM the License. You may obtain a copy of the License at REM REM http://www.apache.org/licenses/LICENSE-2.0 REM REM Unless required by applicable law or agreed to in writing, software REM distributed under the License is distributed on an "AS IS" BASIS, REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. REM See the License for the specific language governing permissions and REM limitations under the License. REM $Id: fop.bat 1325624 2012-04-13 06:28:25Z gadams $ SETLOCAL ENABLEDELAYEDEXPANSION rem %~dp0 is the expanded pathname of the current script under NT set LOCAL_FOP_HOME= if "%OS%"=="Windows_NT" set LOCAL_FOP_HOME="%~dp0" rem Code from Apache Ant project rem Slurp the command line arguments. This loop allows for an unlimited number rem of arguments (up to the command line limit, anyway). rem Could also do a "shift" and "%*" for all params, but apparently doesn't work rem with Win9x. set FOP_CMD_LINE_ARGS=%1 if ""%1""=="""" goto doneStart shift :setupArgs if ""%1""=="""" goto doneStart set FOP_CMD_LINE_ARGS=%FOP_CMD_LINE_ARGS% %1 shift goto setupArgs rem This label provides a place for the argument list loop to break out rem and for NT handling to skip to. :doneStart set LOGCHOICE= rem The default commons logger for JDK1.4 is JDK1.4Logger. rem To use a different logger, uncomment the one desired below rem set LOGCHOICE=-Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.NoOpLog rem set LOGCHOICE=-Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.SimpleLog rem set LOGCHOICE=-Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.Log4JLogger set LOGLEVEL= rem Logging levels rem Below option is only if you are using SimpleLog instead of the default JDK1.4 Logger. rem To set logging levels for JDK 1.4 Logger, edit the %JAVA_HOME%\JRE\LIB\logging.properties rem file instead. rem Possible SimpleLog values: "trace", "debug", "info" (default), "warn", "error", or "fatal". rem set LOGLEVEL=-Dorg.apache.commons.logging.simplelog.defaultlog=INFO set LIBDIR=%LOCAL_FOP_HOME%lib set LOCALCLASSPATH=%FOP_HYPHENATION_PATH% for %%l in (%LOCAL_FOP_HOME%build\*.jar %LIBDIR%\*.jar) do set LOCALCLASSPATH=!LOCALCLASSPATH!;%%l set JAVAOPTS=-Denv.windir=%WINDIR% -Djava.awt.headless=true if "%JAVA_HOME%" == "" goto noJavaHome if not exist "%JAVA_HOME%\bin\java.exe" goto noJavaHome if "%JAVACMD%" == "" set JAVACMD=%JAVA_HOME%\bin\java goto runFop :noJavaHome if "%JAVACMD%" == "" set JAVACMD=java :runFop rem echo "%JAVACMD%" %LOGCHOICE% %LOGLEVEL% -cp "%LOCALCLASSPATH%" org.apache.fop.cli.Main %FOP_CMD_LINE_ARGS% "%JAVACMD%" %JAVAOPTS% %LOGCHOICE% %LOGLEVEL% -cp "%LOCALCLASSPATH%" %FOP_OPTS% org.apache.fop.cli.Main %FOP_CMD_LINE_ARGS% ENDLOCAL
# | Change | User | Description | Committed | |
---|---|---|---|---|---|
#1 | 26953 | Paul Allen | Move //guest/perforce_software/p4convert to //guest/perforce_software/p4convert/main | ||
//guest/perforce_software/p4convert/docs/fop-1.1/fop.bat | |||||
#2 | 14806 | Paul Allen | Update docs and add +w. | ||
#1 | 13920 | Paul Allen | copy part 2 (no errors) | ||
//guest/paul_allen/p4convert-maven/docs/fop-1.1/fop.bat | |||||
#1 | 13895 | Paul Allen | Copying using p4convert-docbook | ||
//guest/perforce_software/doc_build/main/fop-1.1/fop.bat | |||||
#1 | 12728 | eedwards |
Upgrade ANT doc build infrastructure to assemble PDFs: - remove non-namespaced DocBook source and add namespaced DocBook source. - add Apache FOP 1.1 - copy fonts, images, XSL into _build, establishing new asset structure. The original structure remains until all guides using it can be upgraded, and several other issues can be resolved. - updated build.xml to allow for per-target build properties. - upgraded the P4SAG to use the new infrastructure. - tweaked admonition presentation in PDFs to remove admonition graphics, and resemble closely the presentation used in the new HTML layout, including the same colors. With these changes, building PDFs involves using a shell, navigating into the guide's directory (just P4SAG for now), and executing "ant pdf". Issues still to be resolved: - PDF generation encounters several warnings about missing fonts (bold versions of Symbol and ZapfDingbats), and a couple of locations where the page content exceeds the defined content area. - Due to issues within Apache FOP, PDF generation emits a substantial amount of output that is not easily suppressed without losing important warning information. - Apache FOP's interface to ANT does not expose a way to set the font base directory. The current configuration does work under Mac OSX, but further testing on Windows will need to be done to determine if the relative paths defined continue to work. The workaround is for Windows users to customize the fop-config.xml to provide absolute system paths to the required fonts. - HTML generation needs further browser testing, and exhibits broken navigation on iOS browsers within the TOC sidebar. - A number of PDF and HTML presentation tweaks still need to be made, for example: sidebars, gui* DocBook tags, whitespace, section separation, etc. |