Changeset eb522e8 in mainline for tools/check.sh


Ignore:
Timestamp:
2011-06-01T08:43:42Z (14 years ago)
Author:
Lubos Slovak <lubos.slovak@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
8d6c1f1
Parents:
9e2e715 (diff), e51a514 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent.
Message:

Huuuuuge merge from development - all the work actually :)

File:
1 moved

Legend:

Unmodified
Added
Removed
  • tools/check.sh

    • Property mode changed from 100644 to 100755
    r9e2e715 reb522e8  
     1#! /bin/bash
     2
    13#
    2 # Copyright (c) 2010 Martin Decky
     4# Copyright (c) 2010 Jakub Jermar
    35# All rights reserved.
    46#
     
    2729#
    2830
    29 USPACE_PREFIX = ../../..
    30 ROOT_PATH = $(USPACE_PREFIX)/..
     31if [ $1" " == "-h " ];
     32then
     33        echo "Perform pre-integration hands-off build of all profiles."
     34        echo
     35        echo "Syntax:"
     36        echo " $0 [-h] [args...]"
     37        echo
     38        echo " -h        Print this help."
     39        echo " args...   All other args are passed to make (e.g. -j 6)"
     40        echo
    3141
    32 COMMON_MAKEFILE = $(ROOT_PATH)/Makefile.common
    33 CONFIG_MAKEFILE = $(ROOT_PATH)/Makefile.config
     42        exit
     43fi
    3444
    35 -include $(COMMON_MAKEFILE)
    36 -include $(CONFIG_MAKEFILE)
     45FAILED=""
     46PASSED=""
     47PROFILES=""
     48DIRS=`find defaults/ -name Makefile.config | sed 's/^defaults\/\(.*\)\/Makefile.config/\1/' | sort`
    3749
    38 ifeq ($(CONFIG_NETIF_NIL_BUNDLE),y)
    39         LO_SOURCE = lo.netif_nil_bundle
    40         NE2K_SOURCE = ne2k.netif_nil_bundle
    41 else
    42         LO_SOURCE = lo.netif_standalone
    43         NE2K_SOURCE = ne2k.netif_standalone
    44 endif
     50for D in $DIRS;
     51do
     52        for H in $DIRS;
     53        do
     54                if [ `echo $H | grep "^$D\/.*"`x != "x"  ];
     55                then
     56                        continue 2
     57                fi
     58        done
     59        PROFILES="$PROFILES $D"
     60done
    4561
    46 LO_TARGET = lo
    47 NE2K_TARGET = ne2k
     62echo ">>> Going to build the following profiles:"
     63echo $PROFILES
    4864
    49 .PHONY: all clean
     65for P in $PROFILES;
     66do
     67        echo -n ">>>> Building $P... "
     68        ( make distclean && make PROFILE=$P HANDS_OFF=y $1 ) >>/dev/null 2>>/dev/null
     69        if [ $? -ne 0 ];
     70        then
     71                FAILED="$FAILED $P"
     72                echo "failed."
     73        else
     74                PASSED="$PASSED $P"
     75                echo "ok."
     76        fi
     77done
    5078
    51 all: $(LO_TARGET) $(NE2K_TARGET)
     79echo ">>> Done."
     80echo
    5281
    53 clean:
    54         rm -f $(LO_TARGET) $(NE2K_TARGET)
     82echo ">>> The following profiles passed:"
     83echo $PASSED
     84echo
    5585
    56 $(LO_TARGET): $(LO_SOURCE)
    57         cp $< $@
     86echo ">>> The following profiles failed:"
     87echo $FAILED
     88echo
    5889
    59 $(NE2K_TARGET): $(NE2K_SOURCE)
    60         cp $< $@
Note: See TracChangeset for help on using the changeset viewer.