This Trac instance is not used for development anymore!

We migrated our development workflow to git and Gitea.
To test the future redirection, replace trac by ariadne in the page URL.

source: ps/trunk/build/premake/premake5/contrib/mbedtls/yotta/create-module.sh

Last change on this file was 20366, checked in by Itms, 7 years ago

Alpha 12 version of Premake 5, including prebuilt binary for Windows.
Directly taken from https://premake.github.io/.

Refs #3729.

File size: 1.2 KB
Line 
1#!/bin/sh
2
3set -eu
4
5# relative to the script's directory
6TREE=..
7DEST=module
8
9# make sure we're running in our own directory
10if [ -f create-module.sh ]; then :; else
11 cd $( dirname $0 )
12 if [ -f create-module.sh ]; then :; else
13 echo "Please run the script from is directory." >&2
14 exit 1
15 fi
16fi
17
18# use a temporary directory to build the module, then rsync to DEST
19# this allows touching only new files, for more efficient re-builds
20TMP=$DEST-tmp
21rm -rf $TMP
22
23mkdir -p $TMP/mbedtls $TMP/source
24cp $TREE/include/mbedtls/*.h $TMP/mbedtls
25cp $TREE/library/*.c $TMP/source
26
27# temporary, should depend on external module later
28cp data/entropy_hardware_poll.c $TMP/source
29cp data/target_config.h $TMP/mbedtls
30
31data/adjust-config.sh $TREE/scripts/config.pl $TMP/mbedtls/config.h
32
33mkdir -p $TMP/test
34cp -r data/example-* $TMP/test
35# later we should have the generated test suites here too
36
37cp data/module.json $TMP
38cp data/README.md $TMP
39
40cp ../LICENSE $TMP
41if [ -f ../apache-2.0.txt ]; then cp ../apache-2.0.txt $TMP; fi
42
43mkdir -p $DEST
44rsync -cr --delete --exclude build --exclude yotta_\* $TMP/ $DEST/
45rm -rf $TMP
46
47echo "mbed TLS yotta module created in '$PWD/$DEST'."
Note: See TracBrowser for help on using the repository browser.