summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKinsey Moore <kinsey.moore@oarcorp.com>2022-07-12 10:25:25 -0500
committerKinsey Moore <kinsey.moore@oarcorp.com>2022-07-12 14:57:24 -0500
commit2241e79e435d93f7bbf3c8a4595f3f1767ce080c (patch)
tree501c19d64c52c865a7ac86093b1909401078905a
parent45138c5c3311e508b5e8834f78e84cc745033016 (diff)
Ensure that liblwip.a and headers get installedHEADmain
-rw-r--r--lwip.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/lwip.py b/lwip.py
index d22c03a..f565deb 100644
--- a/lwip.py
+++ b/lwip.py
@@ -137,6 +137,20 @@ def build(bld):
target = 'lwip',
cflags='-g -Wall -O0',
use=['lwip_obj', 'driver_obj'])
+ bld.install_files("${PREFIX}/" + arch_lib_path, ["liblwip.a"])
+
+ def install_headers(root_path):
+ for root, dirs, files in os.walk(root_path):
+ for name in files:
+ ext = os.path.splitext(name)[1]
+ src_root = os.path.split(root)
+ path = os.path.join(src_root[0], src_root[1])
+ if ext == '.h':
+ subpath = path.removeprefix(root_path).removeprefix("/")
+ bld.install_files("${PREFIX}/" + arch_lib_path + "/include/" + subpath,
+ os.path.join(path,name))
+
+ [install_headers(path) for path in (drv_incl + common_includes).split(' ')[:-1]]
bld.program(features='c',
target='networking01.exe',