qpcpp/doxygen/make.bat

92 lines
3.1 KiB
Batchfile
Raw Normal View History

2013-12-30 17:41:15 -05:00
@echo off
:: ==========================================================================
:: Product: QP/C++ script for generating Doxygen documentation
2017-07-06 13:31:32 -04:00
:: Last Updated for Version: 5.9.4
:: Date of the Last Update: 2017-07-05
2014-09-22 11:48:11 -04:00
::
:: Q u a n t u m L e a P s
:: ---------------------------
:: innovating embedded systems
::
:: Copyright (C) Quantum Leaps, LLC. All rights reserved.
::
:: This program is open source software: you can redistribute it and/or
:: modify it under the terms of the GNU General Public License as published
:: by the Free Software Foundation, either version 3 of the License, or
:: (at your option) any later version.
::
:: Alternatively, this program may be distributed and modified under the
:: terms of Quantum Leaps commercial licenses, which expressly supersede
:: the GNU General Public License and are specifically designed for
:: licensees interested in retaining the proprietary status of their code.
::
:: This program is distributed in the hope that it will be useful,
:: but WITHOUT ANY WARRANTY; without even the implied warranty of
:: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
:: GNU General Public License for more details.
::
:: You should have received a copy of the GNU General Public License
:: along with this program. If not, see <http://www.gnu.org/licenses/>.
::
:: Contact information:
2017-05-17 13:15:09 -04:00
:: https://state-machine.com
2015-09-29 11:34:38 -04:00
:: mailto:info@state-machine.com
2013-12-30 17:41:15 -05:00
:: ==========================================================================
setlocal
2015-05-14 16:05:04 -04:00
echo usage:
echo make
echo make -CHM
2013-12-30 17:41:15 -05:00
2017-07-06 13:31:32 -04:00
set VERSION=5.9.4
2013-12-30 17:41:15 -05:00
2015-05-14 16:05:04 -04:00
:: Generate Resource Standard Metrics for QP/C++ .............................
2014-04-13 21:35:34 -04:00
set DOXHOME="C:\tools\doxygen\bin"
2013-12-30 17:41:15 -05:00
set RCMHOME="C:\tools\MSquared\M2 RSM"
2016-04-01 13:55:34 -04:00
set RSM_OUTPUT=metrics.dox
2015-05-14 16:05:04 -04:00
set RSM_INPUT=..\include\*.h ..\source\*.h ..\source\*.cpp
2013-12-30 17:41:15 -05:00
2015-05-22 20:38:16 -04:00
echo /** @page metrics Code Metrics > %RSM_OUTPUT%
2013-12-30 17:41:15 -05:00
echo.>> %RSM_OUTPUT%
2015-05-22 20:38:16 -04:00
echo @code >> %RSM_OUTPUT%
echo Standard Code Metrics for QP/C++ %VERSION% >> %RSM_OUTPUT%
2013-12-30 17:41:15 -05:00
%RCMHOME%\rsm.exe -fd -xNOCOMMAND -xNOCONFIG -u"File cfg rsm_qpcpp.cfg" %RSM_INPUT% >> %RSM_OUTPUT%
2015-05-22 20:38:16 -04:00
echo @endcode >> %RSM_OUTPUT%
2013-12-30 17:41:15 -05:00
echo */ >> %RSM_OUTPUT%
2015-05-14 16:05:04 -04:00
:: Generate Doxygen Documentation ...........................................
2014-09-22 11:48:11 -04:00
if "%1"=="-CHM" (
2015-05-14 16:05:04 -04:00
echo Generating HTML...
2014-09-22 11:48:11 -04:00
::( type Doxyfile & echo GENERATE_HTMLHELP=YES ) | %DOXHOME%\doxygen.exe -
%DOXHOME%\doxygen.exe Doxyfile-CHM
2015-05-14 16:05:04 -04:00
echo Adding custom images...
xcopy preview.js tmp\
xcopy img tmp\img\
echo img\img.htm >> tmp\index.hhp
echo Generate CHM...
"C:\tools\HTML Help Workshop\hhc.exe" tmp\index.hhp
echo Cleanup...
rmdir /S /Q tmp
2015-09-29 11:34:38 -04:00
echo CHM file generated in ..\..\html\qpcpp\
2014-09-22 11:48:11 -04:00
) else (
2015-05-14 16:05:04 -04:00
echo Cleanup...
2015-09-29 11:34:38 -04:00
rmdir /S /Q ..\..\html\qpcpp
2015-05-14 16:05:04 -04:00
echo Adding custom images...
2015-09-29 11:34:38 -04:00
xcopy preview.js ..\..\html\qpcpp\
xcopy img ..\..\html\qpcpp\img\
copy images\favicon.ico ..\..\html\qpcpp
2015-05-14 16:05:04 -04:00
echo Generating HTML...
2014-09-22 11:48:11 -04:00
%DOXHOME%\doxygen.exe Doxyfile
)
2013-12-30 17:41:15 -05:00
endlocal