mirror of
https://github.com/hufrea/byedpi.git
synced 2024-12-22 22:35:39 +00:00
commit
f513a06001
@ -103,19 +103,39 @@ if( WIN32 )
|
|||||||
"service_restart.bat" "Service restart"
|
"service_restart.bat" "Service restart"
|
||||||
)
|
)
|
||||||
|
|
||||||
file( WRITE "${CMAKE_BINARY_DIR}/ver.nsi" "VIProductVersion ${MAIN_VERSION}.0\n" )
|
# Attributes section (installer version info)
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIFileVersion ${PROJECT_VERSION}\n" )
|
string( REPLACE ";" "" CPACK_NSIS_DEFINES
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIAddVersionKey /LANG=0 \"ProductVersion\" \"${MAIN_VERSION}.0\"\n" )
|
"VIProductVersion ${PROJECT_VERSION}\n"
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIAddVersionKey /LANG=0 \"FileVersion\" \"${PROJECT_VERSION}\"\n" )
|
"VIFileVersion ${PROJECT_VERSION}\n"
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIAddVersionKey /LANG=0 \"ProductName\" \"${PROJECT_NAME}\"\n" )
|
"VIAddVersionKey /LANG=0 \"ProductVersion\" \"${PROJECT_VERSION}\"\n"
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIAddVersionKey /LANG=0 \"FileDescription\" \"${PROJECT_DESCRIPTION}\"\n" )
|
"VIAddVersionKey /LANG=0 \"FileVersion\" \"${PROJECT_VERSION}\"\n"
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIAddVersionKey /LANG=0 \"CompanyName\" \"${PROJECT_VENDOR}\"\n" )
|
"VIAddVersionKey /LANG=0 \"ProductName\" \"${CPACK_PACKAGE_DESCRIPTION}\"\n"
|
||||||
file( APPEND "${CMAKE_BINARY_DIR}/ver.nsi" "VIAddVersionKey /LANG=0 \"LegalCopyright\" \"${PROJECT_COPYRIGHT}\"\n" )
|
"VIAddVersionKey /LANG=0 \"FileDescription\" \"${CPACK_PACKAGE_DESCRIPTION}\"\n"
|
||||||
set( CPACK_NSIS_EXECUTABLE_PRE_ARGUMENTS "V0 ${CMAKE_BINARY_DIR}/ver.nsi" )
|
"VIAddVersionKey /LANG=0 \"CompanyName\" \"${PROJECT_VENDOR}\"\n"
|
||||||
|
"VIAddVersionKey /LANG=0 \"LegalCopyright\" \"${PROJECT_COPYRIGHT}\""
|
||||||
|
)
|
||||||
|
|
||||||
|
# Preinstall section
|
||||||
|
string( REPLACE ";" "" CPACK_NSIS_EXTRA_PREINSTALL_COMMANDS
|
||||||
|
" ExecWait \"sc stop ${PROJECT_NAME}\""
|
||||||
|
)
|
||||||
|
|
||||||
|
# Install section
|
||||||
|
string( REPLACE ";" "" CPACK_NSIS_EXTRA_INSTALL_COMMANDS
|
||||||
|
"Push \"InstallLocation\"\n"
|
||||||
|
"Push \"$INSTDIR\\\"\n"
|
||||||
|
"Call ConditionalAddToRegistry\n"
|
||||||
|
"Push \"Comments\"\n"
|
||||||
|
"Push \"${CPACK_PACKAGE_DESCRIPTION}\"\n"
|
||||||
|
"Call ConditionalAddToRegistry\n"
|
||||||
|
"ExecWait \"$INSTDIR\\service_install.bat\""
|
||||||
|
)
|
||||||
|
|
||||||
|
# Uninstall section
|
||||||
|
string( REPLACE ";" "" CPACK_NSIS_EXTRA_UNINSTALL_COMMANDS
|
||||||
|
"ExecWait \"$INSTDIR\\service_delete.bat\""
|
||||||
|
)
|
||||||
|
|
||||||
set( CPACK_NSIS_EXTRA_PREINSTALL_COMMANDS "ExecWait \"sc stop ${PROJECT_NAME}\"" )
|
|
||||||
set( CPACK_NSIS_EXTRA_INSTALL_COMMANDS "ExecWait \"$INSTDIR\\service_install.bat\"" )
|
|
||||||
set( CPACK_NSIS_EXTRA_UNINSTALL_COMMANDS "ExecWait \"$INSTDIR\\service_delete.bat\"" )
|
|
||||||
set( CPACK_NSIS_CONTACT "${PROJECT_VENDOR}" )
|
set( CPACK_NSIS_CONTACT "${PROJECT_VENDOR}" )
|
||||||
set( CPACK_NSIS_HELP_LINK "${PROJECT_HOMEPAGE_URL}" )
|
set( CPACK_NSIS_HELP_LINK "${PROJECT_HOMEPAGE_URL}" )
|
||||||
set( CPACK_NSIS_URL_INFO_ABOUT "${PROJECT_HOMEPAGE_URL}" )
|
set( CPACK_NSIS_URL_INFO_ABOUT "${PROJECT_HOMEPAGE_URL}" )
|
||||||
|
2
dist/windows/byedpi.bat
vendored
2
dist/windows/byedpi.bat
vendored
@ -1,4 +1,4 @@
|
|||||||
@echo off
|
@echo off
|
||||||
title ByeDPI
|
title ByeDPI
|
||||||
|
|
||||||
"%~dp0ciadpi.exe" --ip 127.0.0.1 --oob 3+s --split 1+s --disorder 3+s --mod-http=h,d --tlsrec 1+s
|
"%~dp0ciadpi.exe" --ip 127.0.0.1 --oob 3+s --split 1 --disorder 3+s --mod-http=h,d --auto=torst --tlsrec 1+s
|
2
dist/windows/service_install.bat
vendored
2
dist/windows/service_install.bat
vendored
@ -11,7 +11,7 @@ exit /b 0
|
|||||||
set svc_name="ByeDPI"
|
set svc_name="ByeDPI"
|
||||||
set svc_desc="Local SOCKS proxy server to bypass DPI (Deep Packet Inspection)."
|
set svc_desc="Local SOCKS proxy server to bypass DPI (Deep Packet Inspection)."
|
||||||
|
|
||||||
set svc_bin="\"%~dp0ciadpi.exe\" --ip 127.0.0.1 --oob 3+s --split 1+s --disorder 3+s --mod-http=h,d --tlsrec 1+s"
|
set svc_bin="\"%~dp0ciadpi.exe\" --ip 127.0.0.1 --oob 3+s --split 1 --disorder 3+s --mod-http=h,d --auto=torst --tlsrec 1+s"
|
||||||
|
|
||||||
sc stop %svc_name%
|
sc stop %svc_name%
|
||||||
sc delete %svc_name%
|
sc delete %svc_name%
|
||||||
|
Loading…
Reference in New Issue
Block a user