blob: d4da8c4b9d9f3a6a69ff655e2ccc52dcd94600d2 [file] [log] [blame]
Alexander Afanasyev2aa39622014-01-22 11:51:11 -08001# -*- Mode: python; py-indent-offset: 4; indent-tabs-mode: nil; coding: utf-8; -*-
Alexander Afanasyev9bcbc7c2014-04-06 19:37:37 -07002"""
Davide Pesavento0064c1d2018-03-03 18:43:53 -05003Copyright (c) 2014-2018, Regents of the University of California,
taylorchu5ae28772015-03-08 17:45:52 -07004 Arizona Board of Regents,
5 Colorado State University,
6 University Pierre & Marie Curie, Sorbonne University,
7 Washington University in St. Louis,
8 Beijing Institute of Technology,
9 The University of Memphis.
Alexander Afanasyev9bcbc7c2014-04-06 19:37:37 -070010
11This file is part of NFD (Named Data Networking Forwarding Daemon).
12See AUTHORS.md for complete list of NFD authors and contributors.
13
14NFD is free software: you can redistribute it and/or modify it under the terms
15of the GNU General Public License as published by the Free Software Foundation,
16either version 3 of the License, or (at your option) any later version.
17
18NFD is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
19without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
20PURPOSE. See the GNU General Public License for more details.
21
22You should have received a copy of the GNU General Public License along with
23NFD, e.g., in COPYING.md file. If not, see <http://www.gnu.org/licenses/>.
24"""
Alexander Afanasyev2aa39622014-01-22 11:51:11 -080025
Davide Pesavento0064c1d2018-03-03 18:43:53 -050026from waflib import Context, Logs, Utils
27import os, subprocess
Alexander Afanasyev97e4cac2014-03-28 10:55:11 -070028
Alexander Afanasyev782a1d12018-05-02 16:23:26 -040029VERSION = '0.6.2'
Davide Pesavento0064c1d2018-03-03 18:43:53 -050030APPNAME = 'nfd'
31BUGREPORT = 'https://redmine.named-data.net/projects/nfd'
32URL = 'https://named-data.net/doc/NFD/'
33GIT_TAG_PREFIX = 'NFD-'
Alexander Afanasyev2aa39622014-01-22 11:51:11 -080034
35def options(opt):
Alexander Afanasyev5cda2e02014-04-11 13:58:44 -070036 opt.load(['compiler_cxx', 'gnu_dirs'])
Davide Pesavento5f35f642018-05-10 19:36:03 -040037 opt.load(['default-compiler-flags', 'compiler-features',
38 'coverage', 'pch', 'sanitizers', 'boost',
Davide Pesavento67f30272016-08-10 01:55:16 +000039 'dependency-checker', 'unix-socket', 'websocket',
40 'doxygen', 'sphinx_build'],
Alexander Afanasyev97e4cac2014-03-28 10:55:11 -070041 tooldir=['.waf-tools'])
Alexander Afanasyev2aa39622014-01-22 11:51:11 -080042
43 nfdopt = opt.add_option_group('NFD Options')
Alexander Afanasyev885a85b2014-04-12 21:01:13 -070044 opt.addUnixOptions(nfdopt)
Wentao Shang53df1632014-04-21 12:01:32 -070045 opt.addWebsocketOptions(nfdopt)
Davide Pesavento67f30272016-08-10 01:55:16 +000046
Alexander Afanasyev885a85b2014-04-12 21:01:13 -070047 opt.addDependencyOptions(nfdopt, 'libpcap')
48 nfdopt.add_option('--without-libpcap', action='store_true', default=False,
Davide Pesavento0064c1d2018-03-03 18:43:53 -050049 help='Disable libpcap (Ethernet face support will be disabled)')
Alexander Afanasyev885a85b2014-04-12 21:01:13 -070050
Davide Pesavento0064c1d2018-03-03 18:43:53 -050051 opt.addDependencyOptions(nfdopt, 'librt')
52 opt.addDependencyOptions(nfdopt, 'libresolv')
Alexander Afanasyev5cda2e02014-04-11 13:58:44 -070053
Alexander Afanasyev97e4cac2014-03-28 10:55:11 -070054 nfdopt.add_option('--with-tests', action='store_true', default=False,
Davide Pesavento0064c1d2018-03-03 18:43:53 -050055 help='Build unit tests')
Ilya Moiseenko96b80bb2014-04-05 20:53:27 -040056 nfdopt.add_option('--with-other-tests', action='store_true', default=False,
Davide Pesavento0064c1d2018-03-03 18:43:53 -050057 help='Build other tests')
Steve DiBenedetto84da5bf2014-03-11 14:51:29 -060058
Davide Pesavento0064c1d2018-03-03 18:43:53 -050059PRIVILEGE_CHECK_CODE = '''
60#include <unistd.h>
61#include <grp.h>
62#include <pwd.h>
63int main()
64{
65 sysconf(_SC_GETGR_R_SIZE_MAX);
66
67 char buffer[100];
68 group grp;
69 group* grpRes;
70 getgrnam_r("nogroup", &grp, buffer, 100, &grpRes);
71 passwd pwd;
72 passwd* pwdRes;
73 getpwnam_r("nobody", &pwd, buffer, 100, &pwdRes);
74
75 int ret = setegid(grp.gr_gid);
76 ret = seteuid(pwd.pw_uid);
77 (void)(ret);
78
79 getegid();
80 geteuid();
81}
82'''
Alexander Afanasyev8269a052015-02-09 16:25:36 -080083
Alexander Afanasyev2aa39622014-01-22 11:51:11 -080084def configure(conf):
Beichuan Zhang55b8ed42014-04-26 22:25:44 -070085 conf.load(['compiler_cxx', 'gnu_dirs',
Davide Pesavento5f35f642018-05-10 19:36:03 -040086 'default-compiler-flags', 'compiler-features',
87 'pch', 'boost', 'dependency-checker', 'websocket',
Davide Pesavento67f30272016-08-10 01:55:16 +000088 'doxygen', 'sphinx_build'])
Alexander Afanasyevefea8fe2014-03-23 00:00:35 -070089
Davide Pesaventof0ae4422014-05-05 16:32:12 +020090 conf.find_program('bash', var='BASH')
91
taylorchu5ae28772015-03-08 17:45:52 -070092 if 'PKG_CONFIG_PATH' not in os.environ:
Alexander Afanasyevcdb8f362015-03-30 10:52:54 -070093 os.environ['PKG_CONFIG_PATH'] = Utils.subst_vars('${LIBDIR}/pkgconfig', conf.env)
Alexander Afanasyev4a771362014-04-24 21:29:33 -070094 conf.check_cfg(package='libndn-cxx', args=['--cflags', '--libs'],
95 uselib_store='NDN_CXX', mandatory=True)
Davide Pesavento44deacc2014-02-19 10:48:07 +010096
Davide Pesaventob499a602014-11-18 22:36:56 +010097 conf.checkDependency(name='librt', lib='rt', mandatory=False)
98 conf.checkDependency(name='libresolv', lib='resolv', mandatory=False)
99
Alexander Afanasyev748e9892015-01-28 15:07:41 -0800100 if not conf.check_cxx(msg='Checking if privilege drop/elevation is supported', mandatory=False,
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500101 define_name='HAVE_PRIVILEGE_DROP_AND_ELEVATE', fragment=PRIVILEGE_CHECK_CODE):
Junxiao Shia5765d62017-08-09 04:07:46 +0000102 Logs.warn('Dropping privileges is not supported on this platform')
Alexander Afanasyev748e9892015-01-28 15:07:41 -0800103
Davide Pesaventoaaa5dd32016-09-02 12:33:33 +0000104 conf.check_cxx(header_name='valgrind/valgrind.h', define_name='HAVE_VALGRIND', mandatory=False)
Alexander Afanasyev49343f62015-01-26 21:58:07 -0800105
Alexander Afanasyev2aa39622014-01-22 11:51:11 -0800106 if conf.options.with_tests:
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500107 conf.env.WITH_TESTS = True
Davide Pesavento67f30272016-08-10 01:55:16 +0000108 conf.define('WITH_TESTS', 1)
Alexander Afanasyev2aa39622014-01-22 11:51:11 -0800109
Ilya Moiseenko96b80bb2014-04-05 20:53:27 -0400110 if conf.options.with_other_tests:
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500111 conf.env.WITH_OTHER_TESTS = True
Eric Newberry52ae3292017-11-16 13:54:52 -0700112 conf.define('WITH_OTHER_TESTS', 1)
113
114 boost_libs = 'system chrono program_options thread log log_setup'
115 if conf.options.with_tests or conf.options.with_other_tests:
116 boost_libs += ' unit_test_framework'
Ilya Moiseenko96b80bb2014-04-05 20:53:27 -0400117
Yumin Xiaab497452016-05-10 20:23:24 +0800118 conf.check_boost(lib=boost_libs, mt=True)
Davide Pesavento5f35f642018-05-10 19:36:03 -0400119 if conf.env.BOOST_VERSION_NUMBER < 105800:
120 conf.fatal('Minimum required Boost version is 1.58.0\n'
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500121 'Please upgrade your distribution or manually install a newer version of Boost'
122 ' (https://redmine.named-data.net/projects/nfd/wiki/Boost_FAQ)')
Alexander Afanasyevc78b1412014-02-19 14:08:26 -0800123
124 conf.load('unix-socket')
Wentao Shang53df1632014-04-21 12:01:32 -0700125 conf.checkWebsocket(mandatory=True)
Davide Pesavento44deacc2014-02-19 10:48:07 +0100126
Alexander Afanasyev885a85b2014-04-12 21:01:13 -0700127 if not conf.options.without_libpcap:
Davide Pesavento5f35f642018-05-10 19:36:03 -0400128 conf.checkDependency(name='libpcap', lib='pcap', mandatory=True,
129 errmsg='not found, but required for Ethernet face support. '
130 'Specify --without-libpcap to disable Ethernet face support.')
Alexander Afanasyevefea8fe2014-03-23 00:00:35 -0700131
Alexander Afanasyevb5220702017-09-21 18:57:00 -0400132 conf.check_compiler_flags()
133
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500134 # Loading "late" to prevent tests from being compiled with profiling flags
Alexander Afanasyev689569b2014-02-16 20:20:07 -0800135 conf.load('coverage')
Eric Newberry27bdd1a2016-11-01 18:02:54 -0700136 conf.load('sanitizers')
137
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500138 conf.define('DEFAULT_CONFIG_FILE', '%s/ndn/nfd.conf' % conf.env.SYSCONFDIR)
Junxiao Shi759f7062014-11-29 10:19:22 -0700139 # disable assertions in release builds
140 if not conf.options.debug:
141 conf.define('NDEBUG', 1)
Junxiao Shi9f5b01d2016-08-05 03:54:28 +0000142 conf.write_config_header('core/config.hpp')
Alexander Afanasyev2aa39622014-01-22 11:51:11 -0800143
Junxiao Shi09bf7c42014-01-31 11:10:25 -0700144def build(bld):
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700145 version(bld)
146
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500147 bld(features='subst',
148 name='version.hpp',
Junxiao Shi9f5b01d2016-08-05 03:54:28 +0000149 source='core/version.hpp.in',
150 target='core/version.hpp',
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700151 install_path=None,
152 VERSION_STRING=VERSION_BASE,
153 VERSION_BUILD=VERSION,
154 VERSION=int(VERSION_SPLIT[0]) * 1000000 +
155 int(VERSION_SPLIT[1]) * 1000 +
156 int(VERSION_SPLIT[2]),
157 VERSION_MAJOR=VERSION_SPLIT[0],
158 VERSION_MINOR=VERSION_SPLIT[1],
Davide Pesavento67f30272016-08-10 01:55:16 +0000159 VERSION_PATCH=VERSION_SPLIT[2])
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700160
Davide Pesaventoa3148082018-04-12 18:21:54 -0400161 bld.objects(
Alexander Afanasyev613e2a92014-04-15 13:36:58 -0700162 target='core-objects',
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500163 features='pch',
Davide Pesaventoa3148082018-04-12 18:21:54 -0400164 source=bld.path.ant_glob('core/**/*.cpp'),
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500165 use='version.hpp NDN_CXX BOOST LIBRT',
166 includes='.',
Junxiao Shi9f5b01d2016-08-05 03:54:28 +0000167 export_includes='.',
Davide Pesavento67f30272016-08-10 01:55:16 +0000168 headers='core/common.hpp')
Alexander Afanasyev613e2a92014-04-15 13:36:58 -0700169
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500170 nfd_objects = bld.objects(
Alexander Afanasyev613e2a92014-04-15 13:36:58 -0700171 target='daemon-objects',
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500172 source=bld.path.ant_glob('daemon/**/*.cpp',
Davide Pesaventofe0580c2017-05-12 02:02:10 -0400173 excl=['daemon/face/*ethernet*.cpp',
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500174 'daemon/face/pcap*.cpp',
175 'daemon/face/unix*.cpp',
176 'daemon/face/websocket*.cpp',
Alexander Afanasyev97e4cac2014-03-28 10:55:11 -0700177 'daemon/main.cpp']),
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500178 use='core-objects',
Steve DiBenedettoef04f272014-06-04 14:28:31 -0600179 includes='daemon',
Davide Pesavento67f30272016-08-10 01:55:16 +0000180 export_includes='daemon')
Junxiao Shi0fcb41e2014-01-24 10:29:43 -0700181
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500182 if bld.env.HAVE_LIBPCAP:
Davide Pesaventofe0580c2017-05-12 02:02:10 -0400183 nfd_objects.source += bld.path.ant_glob('daemon/face/*ethernet*.cpp')
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500184 nfd_objects.source += bld.path.ant_glob('daemon/face/pcap*.cpp')
Alexander Afanasyev5cda2e02014-04-11 13:58:44 -0700185 nfd_objects.use += ' LIBPCAP'
Davide Pesavento44deacc2014-02-19 10:48:07 +0100186
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500187 if bld.env.HAVE_UNIX_SOCKETS:
188 nfd_objects.source += bld.path.ant_glob('daemon/face/unix*.cpp')
Alexander Afanasyevc78b1412014-02-19 14:08:26 -0800189
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500190 if bld.env.HAVE_WEBSOCKET:
191 nfd_objects.source += bld.path.ant_glob('daemon/face/websocket*.cpp')
192 nfd_objects.use += ' WEBSOCKET'
Wentao Shang53df1632014-04-21 12:01:32 -0700193
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500194 if bld.env.WITH_OTHER_TESTS:
Eric Newberry69b63dc2017-11-04 15:42:46 -0700195 nfd_objects.source += bld.path.ant_glob('tests/other/fw/*.cpp')
196
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500197 bld.objects(target='rib-objects',
198 source=bld.path.ant_glob('rib/**/*.cpp'),
199 use='core-objects')
Alexander Afanasyev3ecec502014-04-16 13:42:44 -0700200
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500201 bld.program(name='nfd',
202 target='bin/nfd',
203 source='daemon/main.cpp',
204 use='daemon-objects rib-objects')
Alexander Afanasyev3ecec502014-04-16 13:42:44 -0700205
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500206 bld.recurse('tools')
207 bld.recurse('tests')
Ilya Moiseenko96b80bb2014-04-05 20:53:27 -0400208
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500209 bld(features='subst',
Alexander Afanasyev97e4cac2014-03-28 10:55:11 -0700210 source='nfd.conf.sample.in',
211 target='nfd.conf.sample',
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500212 install_path='${SYSCONFDIR}/ndn',
213 IF_HAVE_LIBPCAP='' if bld.env.HAVE_LIBPCAP else '; ',
214 IF_HAVE_WEBSOCKET='' if bld.env.HAVE_WEBSOCKET else '; ')
Alexander Afanasyev35fc2b72014-02-13 16:56:21 -0800215
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500216 if bld.env.SPHINX_BUILD:
217 bld(features='sphinx',
218 name='manpages',
219 builder='man',
220 config='docs/conf.py',
221 outdir='docs/manpages',
Alexander Afanasyev49272f72014-04-06 21:49:46 -0700222 source=bld.path.ant_glob('docs/manpages/**/*.rst'),
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500223 install_path='${MANDIR}',
Beichuan Zhang55b8ed42014-04-26 22:25:44 -0700224 VERSION=VERSION)
Junxiao Shi6c135622016-11-21 14:30:33 +0000225 bld.symlink_as('${MANDIR}/man1/nfdc-channel.1', 'nfdc-face.1')
Junxiao Shi6c135622016-11-21 14:30:33 +0000226 bld.symlink_as('${MANDIR}/man1/nfdc-fib.1', 'nfdc-route.1')
227 bld.symlink_as('${MANDIR}/man1/nfdc-register.1', 'nfdc-route.1')
228 bld.symlink_as('${MANDIR}/man1/nfdc-unregister.1', 'nfdc-route.1')
229 bld.symlink_as('${MANDIR}/man1/nfdc-set-strategy.1', 'nfdc-strategy.1')
230 bld.symlink_as('${MANDIR}/man1/nfdc-unset-strategy.1', 'nfdc-strategy.1')
Alexander Afanasyev49272f72014-04-06 21:49:46 -0700231
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500232 bld.install_files('${SYSCONFDIR}/ndn', 'autoconfig.conf.sample')
Alexander Afanasyev5c475972015-12-20 16:16:56 -0800233
Alexander Afanasyev284257b2014-04-11 14:16:51 -0700234def docs(bld):
235 from waflib import Options
236 Options.commands = ['doxygen', 'sphinx'] + Options.commands
237
Alexander Afanasyev35fc2b72014-02-13 16:56:21 -0800238def doxygen(bld):
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700239 version(bld)
240
Alexander Afanasyev35fc2b72014-02-13 16:56:21 -0800241 if not bld.env.DOXYGEN:
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500242 bld.fatal('Cannot build documentation ("doxygen" not found in PATH)')
Beichuan Zhang55b8ed42014-04-26 22:25:44 -0700243
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500244 bld(features='subst',
245 name='doxygen.conf',
246 source=['docs/doxygen.conf.in',
247 'docs/named_data_theme/named_data_footer-with-analytics.html.in'],
248 target=['docs/doxygen.conf',
249 'docs/named_data_theme/named_data_footer-with-analytics.html'],
250 VERSION=VERSION,
251 HTML_FOOTER='../build/docs/named_data_theme/named_data_footer-with-analytics.html' \
252 if os.getenv('GOOGLE_ANALYTICS', None) \
253 else '../docs/named_data_theme/named_data_footer.html',
254 GOOGLE_ANALYTICS=os.getenv('GOOGLE_ANALYTICS', ''))
255
256 bld(features='doxygen',
257 doxyfile='docs/doxygen.conf',
258 use='doxygen.conf')
Alexander Afanasyev49272f72014-04-06 21:49:46 -0700259
260def sphinx(bld):
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700261 version(bld)
262
Beichuan Zhang55b8ed42014-04-26 22:25:44 -0700263 if not bld.env.SPHINX_BUILD:
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500264 bld.fatal('Cannot build documentation ("sphinx-build" not found in PATH)')
265
266 bld(features='sphinx',
267 config='docs/conf.py',
268 outdir='docs',
269 source=bld.path.ant_glob('docs/**/*.rst'),
270 VERSION=VERSION)
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700271
272def version(ctx):
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500273 # don't execute more than once
Alexander Afanasyev26181532014-05-07 23:38:51 -0700274 if getattr(Context.g_module, 'VERSION_BASE', None):
275 return
276
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700277 Context.g_module.VERSION_BASE = Context.g_module.VERSION
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500278 Context.g_module.VERSION_SPLIT = VERSION_BASE.split('.')
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700279
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500280 # first, try to get a version string from git
281 gotVersionFromGit = False
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700282 try:
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700283 cmd = ['git', 'describe', '--always', '--match', '%s*' % GIT_TAG_PREFIX]
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500284 out = subprocess.check_output(cmd, universal_newlines=True).strip()
285 if out:
286 gotVersionFromGit = True
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700287 if out.startswith(GIT_TAG_PREFIX):
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500288 Context.g_module.VERSION = out.lstrip(GIT_TAG_PREFIX)
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700289 else:
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500290 # no tags matched
291 Context.g_module.VERSION = '%s-commit-%s' % (VERSION_BASE, out)
Davide Pesavento5f35f642018-05-10 19:36:03 -0400292 except (OSError, subprocess.CalledProcessError):
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700293 pass
294
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700295 versionFile = ctx.path.find_node('VERSION')
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500296 if not gotVersionFromGit and versionFile is not None:
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700297 try:
298 Context.g_module.VERSION = versionFile.read()
299 return
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500300 except EnvironmentError:
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700301 pass
302
303 # version was obtained from git, update VERSION file if necessary
304 if versionFile is not None:
305 try:
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500306 if versionFile.read() == Context.g_module.VERSION:
307 # already up-to-date
308 return
309 except EnvironmentError as e:
310 Logs.warn('%s exists but is not readable (%s)' % (versionFile, e.strerror))
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700311 else:
312 versionFile = ctx.path.make_node('VERSION')
313
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700314 try:
315 versionFile.write(Context.g_module.VERSION)
Davide Pesavento0064c1d2018-03-03 18:43:53 -0500316 except EnvironmentError as e:
317 Logs.warn('%s is not writable (%s)' % (versionFile, e.strerror))
Alexander Afanasyev48f5a3c2014-08-22 22:33:01 -0700318
Alexander Afanasyevb47d5382014-05-05 14:35:03 -0700319def dist(ctx):
320 version(ctx)
321
322def distcheck(ctx):
323 version(ctx)