From 6a0ba2cdd9467c33a8accf7146962f8bbdd73e44 Mon Sep 17 00:00:00 2001 From: Mike Schuchardt Date: Mon, 22 Jul 2019 16:57:15 -0700 Subject: scripts: Port codegen script from VVL --- scripts/common_codegen.py | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'scripts/common_codegen.py') diff --git a/scripts/common_codegen.py b/scripts/common_codegen.py index 89545326..d56ebac2 100644 --- a/scripts/common_codegen.py +++ b/scripts/common_codegen.py @@ -18,10 +18,7 @@ # # Author: Mark Lobodzinski -import os,re,sys,string -import xml.etree.ElementTree as etree -from generator import * -from collections import namedtuple +import os # Copyright text prefixing all headers (list of strings). prefixStrings = [ @@ -71,3 +68,7 @@ def GetFeatureProtect(interface): if platform is not None: protect = platform_dict[platform] return protect + +# helper to define paths relative to the repo root +def repo_relative(path): + return os.path.abspath(os.path.join(os.path.dirname(__file__), '..', path)) -- cgit v1.2.3