forked from nmap/npcap
-
Notifications
You must be signed in to change notification settings - Fork 0
/
create_examples.bat
37 lines (25 loc) · 1.43 KB
/
create_examples.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
@echo off
IF "%2"=="" (set WPDPACKDESTDIR=.\npcap-sdk\) ELSE (set WPDPACKDESTDIR=%2)
IF ""=="%1" (set WINPCAPSOURCEDIR=.\) ELSE (set WINPCAPSOURCEDIR=%1)
echo Creating \Examples folder
mkdir %WPDPACKDESTDIR% >nul 2>nul
mkdir %WPDPACKDESTDIR%\Examples-pcap >nul 2>nul
mkdir %WPDPACKDESTDIR%\Examples-remote >nul 2>nul
xcopy /s/e/v /Y %WINPCAPSOURCEDIR%\Examples %WPDPACKDESTDIR%\Examples-remote >nul
rem *** Delete Netmeter since it's no more part of the Developer's pack ***
rd /S /Q %WPDPACKDESTDIR%\Examples-remote\NetMeter\
rem *** Delete kdump since the feature is not available at the moment ***
rd /S /Q %WPDPACKDESTDIR%\Examples-remote\kdump\
xcopy /s/e/v /Y %WINPCAPSOURCEDIR%\Examples-pcap %WPDPACKDESTDIR%\Examples-pcap >nul
rem *** Delete WinPcapStress, since it's not a real example ***
rd /S /Q %WPDPACKDESTDIR%\Examples-pcap\winpcap_stress
rem *** Delete stats, since it's not a real example ***
rd /S /Q %WPDPACKDESTDIR%\Examples-pcap\stats
echo Folder \Examples created successfully
set WPDPACKDESTDIR=
set WINPCAPSOURCEDIR=
echo ********************************************************************
echo * *
echo * Now you can build the examples from the developers' pack folder! *
echo * *
echo ********************************************************************