with open(logpath, 'w') as lf:
lf.write(out)
ret = self.error_parser.check(out)
- if ret:
+ if True:
with open(logpath+'.log', 'w') as lf:
lf.write(out)
+ if ret:
raise LocalError(ret)
def package(self, source, cert=None, pkg_type=None, conf=None):
mydict['path'] = path
return mydict
+ def set_user_options(self, c_opts=None, cpp_opts=None, link_opts=None):
+ if c_opts is not None:
+ os.environ['USER_C_OPTS'] = c_opts
+ print 'Set USER_C_OPTS=[%s]' % os.getenv('USER_C_OPTS')
+ if cpp_opts is not None:
+ os.environ['USER_CPP_OPTS'] = cpp_opts
+ print 'Set USER_CPP_OPTS=[%s]' % os.getenv('USER_CPP_OPTS')
+ if link_opts is not None:
+ os.environ['USER_LINK_OPTS'] = link_opts
+ print 'Set USER_LINK_OPTS=[%s]' % os.getenv('USER_LINK_OPTS')
+
def pre_process(self):
if os.path.isfile(os.path.join(self.workspace, self.multi_conf_file)):
build.add_argument('--sdkpath', action='store', dest='sdkpath', \
help='Specify Tizen SDK installation root (one time init).' \
' ex) /home/yours/tizen-sdk/')
+ build.add_argument('--c-opts', action='store', dest='c_opts', \
+ help='Extra compile options USER_C_OPTS')
+ build.add_argument('--cpp-opts', action='store', dest='cpp_opts', \
+ help='Extra compile options USER_CPP_OPTS')
+ build.add_argument('--link-opts', action='store', dest='link_opts', \
+ help='Extra linking options USER_LINK_OPTS')
return parser.parse_args(argv[1:])
"""Command [build] entry point."""
my_source = Source(src=args.workspace)
+ my_source.set_user_options(c_opts=args.c_opts, cpp_opts=args.cpp_opts, link_opts=args.link_opts)
my_sdk = Sdk(sdkpath=args.sdkpath)
my_sdk.clean(my_source)
my_sdk.build_native(my_source, rootstrap=args.rootstrap, arch=args.arch, conf=args.conf, jobs=args.jobs)