diff --git a/bin/UTscapy.bat b/bin/UTscapy.bat new file mode 100755 index 0000000000000000000000000000000000000000..5332145462f797230766a3682527826907a6d6cc --- /dev/null +++ b/bin/UTscapy.bat @@ -0,0 +1,2 @@ +REM Use Python to run the UTscapy script from the current directory, passing all parameters +@python %~dp0\UTscapy %* \ No newline at end of file diff --git a/bin/scapy.bat b/bin/scapy.bat new file mode 100755 index 0000000000000000000000000000000000000000..b6d56a96d1e80699112ff8c7e878c809509e753c --- /dev/null +++ b/bin/scapy.bat @@ -0,0 +1,2 @@ +REM Use Python to run the Scapy script from the current directory, passing all parameters +@python %~dp0\scapy %* \ No newline at end of file diff --git a/setup.py b/setup.py index 2fffd0f9c48cc2f2b0ac781646909ec4bc157c67..477e26d26399960d1b49fcf7b7a62ee391a39377 100755 --- a/setup.py +++ b/setup.py @@ -34,12 +34,16 @@ def make_ezipfile(base_name, base_dir, verbose=0, dry_run=0): archive_util.ARCHIVE_FORMATS["ezip"] = (make_ezipfile,[],'Executable ZIP file') +SCRIPTS = ['bin/scapy','bin/UTscapy'] +# On Windows we also need additional batch files to run the above scripts +if os.name == "nt": + SCRIPTS += ['bin/scapy.bat','bin/UTscapy.bat'] setup( name = 'scapy', version = '2.0.1-dev', packages=['scapy','scapy/arch', 'scapy/arch/windows', 'scapy/layers','scapy/asn1','scapy/tools','scapy/modules'], - scripts = ['bin/scapy','bin/UTscapy'], + scripts = SCRIPTS, data_files = [('share/man/man1', ["doc/scapy.1.gz"])], # Metadata