Commit 45412168 authored by Łukasz Nowak's avatar Łukasz Nowak Committed by Łukasz Nowak

component/quic_client-bin: New component

parent eddb072f
# Command line tool to test QUIC protocol
# This is compiled version provided by Lucas Clemente (thanks!), which
# drastically simplifies https://www.chromium.org/quic/playing-with-quic
# approach, which requires big chunks of Chromium compilation environment
[buildout]
extends =
# running
../nss/buildout.cfg
../nspr/buildout.cfg
../glib/buildout.cfg
../pcre/buildout.cfg
../libffi/buildout.cfg
../zlib/buildout.cfg
../libuuid/buildout.cfg
# compilation
../git/buildout.cfg
parts =
quic_client-bin
[quic_client-bin]
recipe = slapos.recipe.build
url = https://github.com/lucas-clemente/quic-clients/archive/557cb1f99f591614d474e182b50cfee9334e0ffd.zip
md5sum = e2c78f4f7fb6ed03f6eec25b5e54fed3
slapos_promise =
file:quic_client
file:client-linux-debug
library =
${nss:location}/lib
${nspr:location}/lib
${glib:location}/lib
${pcre:location}/lib
${libffi:location}/lib
${zlib:location}/lib
${libuuid:location}/lib
script =
import glob
location = %(location)r
self.failIfPathExists(location)
url = self.options['url']
md5sum = self.options['md5sum']
extract_dir = self.extract(self.download(url, md5sum))
os.mkdir(location)
source_file = glob.glob(os.path.join(extract_dir, '*', 'client-linux-debug'))[0]
shutil.copy(source_file, location)
wrapper_path = os.path.join(location, 'quic_client')
with open(wrapper_path, 'w') as f:
f.write("""#!/bin/sh -e
export LD_LIBRARY_PATH={}
exec {}/client-linux-debug "$@"
""".format(
':'.join(self.options['library'].split()),
location
))
os.fchmod(f.fileno(), 0o755)
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment