PORTNAME=	binwalk
PORTVERSION=	3.1.0
DISTVERSIONPREFIX=	v
CATEGORIES=	security

MAINTAINER=	pi@FreeBSD.org
COMMENT=	Search binary images for embedded files and executable code
WWW=		https://github.com/ReFirmLabs/binwalk

LICENSE=	MIT

# yeslogic-fontconfig-sys needs this
LIB_DEPENDS=	libfontconfig.so:x11-fonts/fontconfig

USES=		cargo pkgconfig
USE_GITHUB=	yes
GH_ACCOUNT=	ReFirmLabs
PLIST_FILES=	bin/binwalk

CARGO_CRATES=	adler-1.0.2 \
		adler2-2.0.0 \
		aho-corasick-1.1.3 \
		android-tzdata-0.1.1 \
		android_system_properties-0.1.5 \
		anstream-0.6.15 \
		anstyle-1.0.8 \
		anstyle-parse-0.2.5 \
		anstyle-query-1.1.1 \
		anstyle-wincon-3.0.4 \
		autocfg-1.3.0 \
		base64-0.22.1 \
		bitflags-1.3.2 \
		bitflags-2.6.0 \
		bumpalo-3.16.0 \
		bytemuck-1.18.0 \
		byteorder-1.5.0 \
		bzip2-0.4.4 \
		bzip2-sys-0.1.11+1.0.8 \
		cc-1.1.21 \
		cfg-if-1.0.0 \
		chrono-0.4.38 \
		clap-4.5.18 \
		clap_builder-4.5.18 \
		clap_derive-4.5.18 \
		clap_lex-0.7.2 \
		color_quant-1.1.0 \
		colorchoice-1.0.2 \
		colored-2.1.0 \
		core-foundation-0.9.4 \
		core-foundation-sys-0.8.7 \
		core-graphics-0.23.2 \
		core-graphics-types-0.1.3 \
		core-text-20.1.0 \
		crc32-v2-0.0.4 \
		crc32c-0.6.8 \
		crc32fast-1.4.2 \
		dirs-5.0.1 \
		dirs-sys-0.4.1 \
		dlib-0.5.2 \
		dwrote-0.11.1 \
		entropy-0.4.2 \
		env_filter-0.1.2 \
		env_logger-0.11.5 \
		fdeflate-0.3.4 \
		flate2-1.0.34 \
		float-ord-0.3.2 \
		font-kit-0.14.2 \
		foreign-types-0.5.0 \
		foreign-types-macros-0.2.3 \
		foreign-types-shared-0.3.1 \
		freetype-sys-0.20.1 \
		getrandom-0.2.15 \
		gif-0.12.0 \
		heck-0.5.0 \
		hermit-abi-0.3.9 \
		humantime-2.1.0 \
		iana-time-zone-0.1.61 \
		iana-time-zone-haiku-0.1.2 \
		image-0.24.9 \
		is_terminal_polyfill-1.70.1 \
		itoa-1.0.11 \
		jpeg-decoder-0.3.1 \
		js-sys-0.3.70 \
		lazy_static-1.5.0 \
		libc-0.2.158 \
		libloading-0.8.5 \
		libredox-0.1.3 \
		log-0.4.22 \
		lzma-sys-0.1.20 \
		memchr-2.7.4 \
		miniz_oxide-0.7.4 \
		miniz_oxide-0.8.0 \
		num-traits-0.2.19 \
		num_cpus-1.16.0 \
		once_cell-1.19.0 \
		option-ext-0.2.0 \
		pathfinder_geometry-0.5.1 \
		pathfinder_simd-0.5.4 \
		pkg-config-0.3.30 \
		plotters-0.3.7 \
		plotters-backend-0.3.7 \
		plotters-bitmap-0.3.7 \
		plotters-svg-0.3.7 \
		png-0.17.13 \
		ppv-lite86-0.2.20 \
		proc-macro2-1.0.86 \
		quote-1.0.37 \
		rand-0.8.5 \
		rand_chacha-0.3.1 \
		rand_core-0.6.4 \
		redox_users-0.4.6 \
		regex-1.10.6 \
		regex-automata-0.4.7 \
		regex-syntax-0.8.4 \
		rustc_version-0.4.1 \
		ryu-1.0.18 \
		same-file-1.0.6 \
		semver-1.0.23 \
		serde-1.0.210 \
		serde_derive-1.0.210 \
		serde_json-1.0.128 \
		shlex-1.3.0 \
		simd-adler32-0.3.7 \
		strsim-0.11.1 \
		syn-2.0.77 \
		termsize-0.1.9 \
		thiserror-1.0.63 \
		thiserror-impl-1.0.63 \
		threadpool-1.8.1 \
		ttf-parser-0.20.0 \
		unicode-ident-1.0.13 \
		utf8parse-0.2.2 \
		uuid-1.10.0 \
		uuid-macro-internal-1.10.0 \
		walkdir-2.5.0 \
		wasi-0.11.0+wasi-snapshot-preview1 \
		wasm-bindgen-0.2.93 \
		wasm-bindgen-backend-0.2.93 \
		wasm-bindgen-macro-0.2.93 \
		wasm-bindgen-macro-support-0.2.93 \
		wasm-bindgen-shared-0.2.93 \
		web-sys-0.3.70 \
		weezl-0.1.8 \
		winapi-0.3.9 \
		winapi-i686-pc-windows-gnu-0.4.0 \
		winapi-util-0.1.9 \
		winapi-x86_64-pc-windows-gnu-0.4.0 \
		windows-core-0.52.0 \
		windows-sys-0.48.0 \
		windows-sys-0.52.0 \
		windows-sys-0.59.0 \
		windows-targets-0.48.5 \
		windows-targets-0.52.6 \
		windows_aarch64_gnullvm-0.48.5 \
		windows_aarch64_gnullvm-0.52.6 \
		windows_aarch64_msvc-0.48.5 \
		windows_aarch64_msvc-0.52.6 \
		windows_i686_gnu-0.48.5 \
		windows_i686_gnu-0.52.6 \
		windows_i686_gnullvm-0.52.6 \
		windows_i686_msvc-0.48.5 \
		windows_i686_msvc-0.52.6 \
		windows_x86_64_gnu-0.48.5 \
		windows_x86_64_gnu-0.52.6 \
		windows_x86_64_gnullvm-0.48.5 \
		windows_x86_64_gnullvm-0.52.6 \
		windows_x86_64_msvc-0.48.5 \
		windows_x86_64_msvc-0.52.6 \
		wio-0.2.2 \
		xxhash-rust-0.8.12 \
		xz2-0.1.7 \
		yeslogic-fontconfig-sys-6.0.0 \
		zerocopy-0.7.35 \
		zerocopy-derive-0.7.35

.include <bsd.port.mk>
