<commit_before>
PKG_NAME := packetdrill
PKG_VER  := d799c219acfa

PKG_SOURCES := https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/packetdrill/source-archive.zip
PKG_MD5     := 1c203d1474022b0aad2364f3ab92494e

PKG_PATCHES := packetdrill.patch

include $(EXTBLD_LIB)

PACKETDRILL_SOURCE_DIR := $(BUILD_DIR)/$(PKG_NAME)/gtests/net/$(PKG_NAME)

$(BUILD) :
	cd $(PACKETDRILL_SOURCE_DIR) && ( \
		$(MAKE) -f Makefile.common \
			MAKEFLAGS='$(EMBOX_IMPORTED_MAKEFLAGS)' \
			CC=$(EMBOX_GCC) \
			CPPFLAGS+="-I$(abspath $(CURDIR))/include -include $(abspath $(CURDIR))/packetdrill_stubs.h" \
	)
	touch $@

$(INSTALL) :
	cp $(PACKETDRILL_SOURCE_DIR)/packetdrill $(PKG_INSTALL_DIR)/packetdrill.o
	touch $@<commit_msg>third-party: Fix packetdrill build with gcc9<commit_after>
PKG_NAME := packetdrill
PKG_VER  := d799c219acfa

PKG_SOURCES := https://storage.googleapis.com/google-code-archive-source/v2/code.google.com/packetdrill/source-archive.zip
PKG_MD5     := 1c203d1474022b0aad2364f3ab92494e

PKG_PATCHES := packetdrill.patch

include $(EXTBLD_LIB)

PACKETDRILL_SOURCE_DIR := $(BUILD_DIR)/$(PKG_NAME)/gtests/net/$(PKG_NAME)

CFLAGS_NO_PACKED =

GCCVERSIONGTEQ9 := $(shell expr `$(EMBOX_GCC) -dumpversion | cut -f1 -d.` \>= 9)

ifeq "$(GCCVERSIONGTEQ9)" "1"
    CFLAGS_NO_PACKED = -Wno-address-of-packed-member
endif

$(BUILD) :
	cd $(PACKETDRILL_SOURCE_DIR) && ( \
		$(MAKE) -f Makefile.common \
			MAKEFLAGS='$(EMBOX_IMPORTED_MAKEFLAGS)' \
			CC=$(EMBOX_GCC) \
			CFLAGS+=$(CFLAGS_NO_PACKED) \
			CPPFLAGS+="-I$(abspath $(CURDIR))/include -include $(abspath $(CURDIR))/packetdrill_stubs.h" \
	)
	touch $@

$(INSTALL) :
	cp $(PACKETDRILL_SOURCE_DIR)/packetdrill $(PKG_INSTALL_DIR)/packetdrill.o
	touch $@
{'fraction_non_alphanumeric': 0.1597222222222222, 'fraction_numerical': 0.03819444444444445, 'mean_word_length': 5.197132616487456, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 4, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4206811', 'n_tokens_mistral': 788, 'n_tokens_neox': 715, 'n_words': 90}