05394a18d4
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@3344 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
153 lines
3.7 KiB
Makefile
153 lines
3.7 KiB
Makefile
# -*- makefile -*-
|
|
#----------------------------------------------------------------------------
|
|
# Name: makefile.nt
|
|
# Purpose: Win32, VC++ 5/6 makefile for wxPython
|
|
#
|
|
# Author: Robin Dunn
|
|
#
|
|
# Created: 3/27/97
|
|
# RCS-ID: $Id$
|
|
# Copyright: (c) 1998 by Total Control Software
|
|
# Licence: wxWindows license
|
|
#----------------------------------------------------------------------------
|
|
VERSION=2.1b2
|
|
|
|
# Set WXDIR to the root wxWindows directory for your system
|
|
WXDIR = $(WXWIN)
|
|
|
|
# Set this to the root of the Python installation
|
|
PYTHONDIR=\progra~1\Python
|
|
|
|
# Set this to 1 for a non-debug, optimised compile
|
|
FINAL=1
|
|
|
|
# Set this to where you want the stuff installed at. It should
|
|
# be a directory contained in a PYTHONPATH directory, and should be
|
|
# named wxPython
|
|
TARGETDIR=$(PYTHONDIR)\wxPython
|
|
|
|
# Set this to 1 for make to pre-compile the Python modules, 0 to
|
|
# just copy the sources and let Python compile them the first
|
|
# time they are imported.
|
|
COMPILEPY=0
|
|
|
|
# If your wxWindows is built as a DLL, set this to 1. Using 0 or unset
|
|
# means that wxWindows will be staticaly linked with wxPython.
|
|
WXUSINGDLL=1
|
|
|
|
# If you want to compile in code to aquire/release the Python
|
|
# Interpreter Lock at the appropriate places
|
|
WXP_USE_THREAD=1
|
|
|
|
|
|
#----------------------------------------------------------------------
|
|
|
|
!if "$(WXP_USE_THREAD)" == "1"
|
|
THREAD=-DWXP_USE_THREAD=1
|
|
!endif
|
|
|
|
#----------------------------------------------------------------------
|
|
|
|
NOPCH=1
|
|
THISDIR=$(WXDIR)\utils\wxPython\modules
|
|
WXPSRCDIR=$(WXDIR)\utils\wxPython\src
|
|
|
|
EXTRALIBS=$(PYTHONDIR)\libs\python15.lib $(WXPSRCDIR)\wxc.lib
|
|
#EXTRALIBS=$(PYTHONDIR)\PCbuild\python15_d.lib -D_DEBUG
|
|
EXTRAINC=-I$(PYTHONDIR)\include -I$(WXPSRCDIR) -I.
|
|
EXTRAFLAGS=/Fpwxp.pch /YXhelpers.h -DSWIG_GLOBAL -DHAVE_CONFIG_H $(THREAD)
|
|
OVERRIDEFLAGS=/GX- $(OTHERCFLAGS)
|
|
|
|
|
|
SWIGFLAGS=-c++ -shadow -python -dnone -D__WXMSW__ -I$(WXPSRCDIR)
|
|
GENCODEDIR=msw
|
|
|
|
|
|
!include $(WXDIR)\src\makevc.env
|
|
|
|
#----------------------------------------------------------------------
|
|
|
|
!if "$(FINAL)" == "1"
|
|
DEBUGLFLAGS = /DEBUG /INCREMENTAL:YES
|
|
!else
|
|
DEBUGLFLAGS = /INCREMENTAL:NO
|
|
!endif
|
|
|
|
LFLAGS= $(DEBUGLFLAGS) /DLL /subsystem:windows,3.50 /machine:I386 /nologo
|
|
|
|
#----------------------------------------------------------------------
|
|
|
|
def: default
|
|
|
|
|
|
showflags:
|
|
@echo $(CPPFLAGS)
|
|
|
|
# implicit rule for compiling .cpp and .c files
|
|
{}.cpp{}.obj:
|
|
$(cc) @<<
|
|
$(CPPFLAGS) /c /Tp $<
|
|
<<
|
|
|
|
{$(GENCODEDIR)}.cpp{}.obj:
|
|
$(cc) @<<
|
|
$(CPPFLAGS) /c /Tp $<
|
|
<<
|
|
|
|
{}.c{}.obj:
|
|
$(cc) @<<
|
|
$(CPPFLAGS) /c $<
|
|
<<
|
|
|
|
|
|
#------------------------------------------------------------------------
|
|
|
|
.SUFFIXES : .i .py
|
|
|
|
# Implicit rules to run SWIG
|
|
{}.i{$(GENCODEDIR)}.cpp:
|
|
swig $(SWIGFLAGS) -c -o $@ $<
|
|
|
|
{}.i{$(GENCODEDIR)}.py:
|
|
swig $(SWIGFLAGS) -c -o $(GENCODEDIR)\tmp_wrap.cpp $<
|
|
-erase $(GENCODEDIR)\tmp_wrap.cpp
|
|
|
|
|
|
{$(GENCODEDIR)}.py{$(TARGETDIR)}.py:
|
|
copy $< $@
|
|
|
|
{}.py{$(TARGETDIR)}.py:
|
|
copy $< $@
|
|
|
|
#{}.py{$(TARGETDIR)}.$(PYEXT):
|
|
# $(PYTHON) -c "import py_compile; py_compile.compile('$<', '$@')"
|
|
|
|
clean:
|
|
-erase *.obj
|
|
-erase *.exe
|
|
-erase *.res
|
|
-erase *.map
|
|
-erase *.sbr
|
|
-erase *.pdb
|
|
-erase *.pch
|
|
-erase $(TARGET).exp
|
|
-erase $(TARGET).lib
|
|
# -erase $(TARGETDIR)\$(TARGET).*
|
|
|
|
dist:
|
|
cd ..\..
|
|
wxPython\distrib\zipit.bat $(VERSION)
|
|
|
|
pycfiles : $(PYMODULES)
|
|
!if "$(COMPILEPY)" == "1"
|
|
$(PYTHONDIR)\python $(PYTHONDIR)\Lib\compileall.py -l $(TARGETDIR)
|
|
$(PYTHONDIR)\python -O $(PYTHONDIR)\Lib\compileall.py -l $(TARGETDIR)
|
|
!endif
|
|
|
|
$(TARGET).res : $(TARGET).rc $(WXDIR)\include\wx\msw\wx.rc
|
|
$(rc) -r /i$(WXDIR)\include -fo$@ $(TARGET).rc
|
|
|
|
sources : $(SOURCES)
|
|
|
|
#----------------------------------------------------------------------
|