"Ported" the makefile to nmake (attached).

mike

# Makefile for the PythonRuntime .NET assembly and tests. Thanks to
# Camilo Uribe <[EMAIL PROTECTED]> for contributing Mono support.

RELEASE=pythonnet-1.0-rc2-py2.4-clr1.1-src
RUNNER=
ILDASM=ildasm
ILASM=ilasm
CSC=csc.exe

all: python.exe CLR.dll Python.Test.dll


python.exe: Python.Runtime.dll
        cd src
    cd console
        $(CSC) /nologo /target:exe /out:../../python.exe \
        /reference:../../Python.Runtime.dll /recurse:*.cs
        cd ..
    cd ..


Python.Runtime.dll: callconvutil.exe
        cd src
    cd runtime
        $(CSC) /nologo /unsafe /target:library /out:../../Python.Runtime.dll \
        /recurse:*.cs
        cd ..
    cd ..
        $(ILDASM) /nobar Python.Runtime.dll /out=Python.Runtime.il
        callconvutil.exe
        $(ILASM) /nologo /quiet /dll \
        /resource=Python.Runtime.res /output=Python.Runtime.dll \
        Python.Runtime.il2
        del Python.Runtime.il
        del Python.Runtime.il2
        del Python.Runtime.res
        del callconvutil.exe


CLR.dll: Python.Runtime.dll
        $(ILASM) /nologo /dll /quiet /output=CLR.dll \
        ./src/runtime/clrmodule.il


Python.Test.dll: Python.Runtime.dll
        cd src
    cd testing
        $(CSC) /nologo /target:library /out:../../Python.Test.dll \
        /reference:../../Python.Runtime.dll \
        /recurse:*.cs
        cd ..
    cd ..


callconvutil.exe:
        cd src
    cd tools
        $(CSC) /nologo /target:exe /out:../../callconvutil.exe \
        /recurse:*.cs
        cd ..
    cd ..


clean:
        del python.exe Python*.dll Python*.il Python*.il2 Python*.res
        del callconvutil.exe
        del CLR.dll
        del .\*~
        cd src
    cd console
    del *~
    cd ..
    cd ..
        cd src
    cd runtime
    del *~
    cd ..
    cd ..
        cd src
    cd testing
    del *~
    cd ..
    cd ..
        cd src
    cd tests
    del *~
    del *.pyc
    cd ..
    cd ..
        cd src
    cd tools
    del *~
    cd ..
    cd ..
        cd doc
    del *~
    cd ..
        cd demo
    del *~
    cd ..


test:
        del .\src\tests\*.pyc
        $(RUNNER) ./python.exe ./src/tests/runtests.py


dist: clean
        mkdir ./$(RELEASE)
        cp -R ./makefile ./$(RELEASE)/
        cp -R ./demo ./$(RELEASE)/
        cp -R ./doc ./$(RELEASE)/
        cp -R ./src ./$(RELEASE)/
        nmake
        cp ./python.exe ./$(RELEASE)/
        cp ./*.dll ./$(RELEASE)/
        tar czf $(RELEASE).tgz ./$(RELEASE)/
        mv $(RELEASE).tgz ./release/
        rm -rf ./$(RELEASE)/


dis:
        $(ILDASM) Python.Runtime.dll /out=Python.Runtime.il


asm:
        $(ILASM) /dll /quiet  \
        /resource=Python.Runtime.res /output=Python.Runtime.dll \
        Python.Runtime.il



_________________________________________________
Python.NET mailing list - [email protected]
http://mail.python.org/mailman/listinfo/pythondotnet

Reply via email to