lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20201104085149.GQ2408@dhcp-12-153.nay.redhat.com>
Date:   Wed, 4 Nov 2020 16:51:49 +0800
From:   Hangbin Liu <haliu@...hat.com>
To:     David Ahern <dsahern@...il.com>
Cc:     Stephen Hemminger <stephen@...workplumber.org>,
        Daniel Borkmann <daniel@...earbox.net>,
        Alexei Starovoitov <ast@...nel.org>,
        Martin KaFai Lau <kafai@...com>,
        Song Liu <songliubraving@...com>, Yonghong Song <yhs@...com>,
        David Miller <davem@...emloft.net>,
        Jesper Dangaard Brouer <brouer@...hat.com>,
        netdev@...r.kernel.org, bpf@...r.kernel.org,
        Jiri Benc <jbenc@...hat.com>,
        Andrii Nakryiko <andrii@...nel.org>,
        Toke Høiland-Jørgensen <toke@...hat.com>
Subject: Re: [PATCHv3 iproute2-next 1/5] configure: add check_libbpf() for
 later libbpf support

On Tue, Nov 03, 2020 at 10:32:37AM -0700, David Ahern wrote:
> configure scripts usually allow you to control options directly,
> overriding the autoprobe.

What do you think of the follow update? It's a little rough and only controls
libbpf.

$ git diff
diff --git a/configure b/configure
index 711bb69c..be35c024 100755
--- a/configure
+++ b/configure
@@ -442,6 +442,35 @@ endif
 EOF
 }

+usage()
+{
+       cat <<EOF
+Usage: $0 [OPTIONS]
+  -h | --help                  Show this usage info
+  --no-libbpf                  build the package without libbpf
+  --libbpf-dir=DIR             build the package with self defined libbpf dir
+EOF
+       exit $1
+}
+
+while true; do
+       case "$1" in
+               --libbpf-dir)
+                       LIBBPF_DIR="$2"
+                       shift 2 ;;
+               --no-libbpf)
+                       NO_LIBBPF_CHECK=1
+                       shift ;;
+               -h | --help)
+                       usage 0 ;;
+               "")
+                       break ;;
+               *)
+                       usage 1 ;;
+       esac
+done
+
+
 echo "# Generated config based on" $INCLUDE >$CONFIG
 quiet_config >> $CONFIG

@@ -476,8 +505,10 @@ check_setns
 echo -n "SELinux support: "
 check_selinux

-echo -n "libbpf support: "
-check_libbpf
+if [ -z $NO_LIBBPF_CHECK ]; then
+       echo -n "libbpf support: "
+       check_libbpf
+fi

 echo -n "ELF support: "
 check_elf


$ ./configure -h
Usage: ./configure [OPTIONS]
  -h | --help                   Show this usage info
  --no-libbpf                   build the package without libbpf
  --libbpf-dir=DIR              build the package with self defined libbpf dir

Thanks
Hangbin

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ