linkchecker/windows/build.bat

51 lines
1.9 KiB
Batchfile
Raw Normal View History

:: Build LinkChecker
2011-04-16 15:30:51 +00:00
:: Copyright (C) 2010-2011 Bastian Kleineidam
:: This program is free 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 2 of the License, or
:: (at your option) any later version.
::
:: 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, write to the Free Software Foundation, Inc.,
:: 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
2009-02-24 10:56:25 +00:00
@echo off
2011-04-19 06:48:29 +00:00
:: Python version
2010-09-22 22:42:56 +00:00
set PYDIR=C:\Python27
2011-04-16 15:30:51 +00:00
set PYVER=2.7
2011-04-19 06:48:29 +00:00
2011-12-26 18:13:47 +00:00
:: PyQt installation
set QTDEV=%PYDIR%\Lib\site-packages\PyQt4
2011-04-19 06:48:29 +00:00
:: END configuration, no need to change anything below
2011-04-25 13:35:20 +00:00
:: set platform architecture
for /f "usebackq tokens=*" %%a in (`%PYDIR%\python.exe -c "from distutils.util import get_platform;print get_platform()"`) do set PLATFORM="%%a"
:: detect compiler
if defined MSSdk (
:: Microsoft SDK
set COMPILER=
set DISTUTILS_USE_SDK=1
2011-04-26 14:05:04 +00:00
) else if "%PLATFORM%" == "win32" (
:: MinGW (only for 32bit platforms)
set COMPILER="-c mingw32"
) else (
echo "No Microsoft SDK or MinGW compiler detected."
goto :finish
)
%PYDIR%\python.exe setup.py sdist --manifest-only
2011-04-16 15:30:51 +00:00
%PYDIR%\python.exe setup.py build %COMPILER%
:: copy .pyd files to start linkchecker in local directory
2011-04-26 14:05:04 +00:00
copy build\lib.%PLATFORM%-%PYVER%\linkcheck\HtmlParser\htmlsax.pyd linkcheck\HtmlParser
copy build\lib.%PLATFORM%-%PYVER%\linkcheck\network\_network.pyd linkcheck\network
2011-04-16 15:30:51 +00:00
:: generate GUI documentation
2011-12-26 18:13:47 +00:00
%QTDEV%\qcollectiongenerator.exe doc\html\lccollection.qhcp -o doc\html\lccollection.qhc
:finish