Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[winpcap] Remove the keyword 'inline' macro #12542

Merged
merged 2 commits into from
Jul 31, 2020
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion ports/winpcap/CONTROL
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Source: winpcap
Version: 4.1.3-3
Version: 4.1.3
Port-Version: 4
Homepage: https://www.winpcap.org
Description: WinPcap is the industry-standard tool for link-layer network access in Windows environments.
53 changes: 16 additions & 37 deletions ports/winpcap/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,7 @@ vcpkg_extract_source_archive_ex(
"${CMAKE_CURRENT_LIST_DIR}/fix-create-lib-batch.patch"
)

file(
COPY
"${CURRENT_PORT_DIR}/create_bin.bat"
DESTINATION
${SOURCE_PATH}
)
file(COPY "${CURRENT_PORT_DIR}/create_bin.bat" DESTINATION ${SOURCE_PATH})

if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
set(PLATFORM Win32)
Expand Down Expand Up @@ -111,8 +106,7 @@ vcpkg_execute_required_process(
LOGNAME create_include-${TARGET_TRIPLET}
)

file(
INSTALL
file(INSTALL
"${SOURCE_PATH}/WpdPack/Include/bittypes.h"
"${SOURCE_PATH}/WpdPack/Include/ip6_misc.h"
"${SOURCE_PATH}/WpdPack/Include/Packet32.h"
Expand All @@ -122,22 +116,17 @@ file(
"${SOURCE_PATH}/WpdPack/Include/pcap-stdinc.h"
"${SOURCE_PATH}/WpdPack/Include/remote-ext.h"
"${SOURCE_PATH}/WpdPack/Include/Win32-Extensions.h"
DESTINATION
${CURRENT_PACKAGES_DIR}/include
)
DESTINATION ${CURRENT_PACKAGES_DIR}/include)

file(
INSTALL
file(INSTALL
"${SOURCE_PATH}/WpdPack/Include/pcap/bluetooth.h"
"${SOURCE_PATH}/WpdPack/Include/pcap/bpf.h"
"${SOURCE_PATH}/WpdPack/Include/pcap/namedb.h"
"${SOURCE_PATH}/WpdPack/Include/pcap/pcap.h"
"${SOURCE_PATH}/WpdPack/Include/pcap/sll.h"
"${SOURCE_PATH}/WpdPack/Include/pcap/usb.h"
"${SOURCE_PATH}/WpdPack/Include/pcap/vlan.h"
DESTINATION
${CURRENT_PACKAGES_DIR}/include/pcap
)
DESTINATION ${CURRENT_PACKAGES_DIR}/include/pcap)

vcpkg_execute_required_process(
COMMAND ${SOURCE_PATH}/create_lib.bat
Expand All @@ -150,21 +139,15 @@ if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
set(PCAP_LIBRARY_PATH "${PCAP_LIBRARY_PATH}/x64")
endif()

file(
INSTALL
file(INSTALL
"${PCAP_LIBRARY_PATH}/Packet.lib"
"${PCAP_LIBRARY_PATH}/wpcap.lib"
DESTINATION
${CURRENT_PACKAGES_DIR}/lib
)
DESTINATION ${CURRENT_PACKAGES_DIR}/lib)

file(
INSTALL
file(INSTALL
"${PCAP_LIBRARY_PATH}/debug/Packet.lib"
"${PCAP_LIBRARY_PATH}/debug/wpcap.lib"
DESTINATION
${CURRENT_PACKAGES_DIR}/debug/lib
)
DESTINATION ${CURRENT_PACKAGES_DIR}/debug/lib)

if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
vcpkg_execute_required_process(
Expand All @@ -178,21 +161,17 @@ if(VCPKG_LIBRARY_LINKAGE STREQUAL "dynamic")
set(PCAP_BINARY_PATH "${PCAP_BINARY_PATH}/x64")
endif()

file(
INSTALL
file(INSTALL
"${PCAP_BINARY_PATH}/Packet.dll"
"${PCAP_BINARY_PATH}/wpcap.dll"
DESTINATION
${CURRENT_PACKAGES_DIR}/bin
)
DESTINATION ${CURRENT_PACKAGES_DIR}/bin)

file(
INSTALL
file(INSTALL
"${PCAP_BINARY_PATH}/Packet.dll"
"${PCAP_BINARY_PATH}/wpcap.dll"
DESTINATION
${CURRENT_PACKAGES_DIR}/debug/bin
)
DESTINATION ${CURRENT_PACKAGES_DIR}/debug/bin)
endif()

configure_file(${COPYRIGHT} ${CURRENT_PACKAGES_DIR}/share/winpcap/copyright COPYONLY)
vcpkg_replace_string(${CURRENT_PACKAGES_DIR}/include/pcap-stdinc.h "#define inline __inline" "#ifndef __cplusplus\n#define inline __inline\n#endif")

configure_file(${COPYRIGHT} ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright COPYONLY)