blob: 8426e8dbe81d0efe7af9e2a0ea4228d156b3c6a6 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
#!/bin/bash
#
# To be ran during the build process to export
# system headers
#
TARGET_DIR=lib/libc/include/sys
SYS_DIR=../../../../sys/include/sys
if [ -f $TARGET_DIR/.sys_export ]
then
exit 0
fi
. builddeps/sysexports
echo "Exporting sys headers..."
cd $TARGET_DIR
for i in $sys_headers
do
if [ -s "$i" ]
then
echo "HEADER CONFLICT ($TARGET_DIR/$i)"
continue
fi
echo "sys/include/sys/$i -> lib/libc/include/sys/$i"
echo include/sys/$i >>.sys_export
echo "$i" >>.gitignore
ln -sf $SYS_DIR/$i .
done
|