Systemd/src/shared/generate-ip-protocol-list.sh

7 lines
171 B
Bash
Raw Normal View History

2017-12-24 07:53:20 +01:00
#!/bin/sh
set -eu
$1 -dM -include netinet/in.h - </dev/null | \
awk '/^#define[ \t]+IPPROTO_[^ \t]+[ \t]+[^ \t]/ { print $2; }' | \
sed -e 's/IPPROTO_//'