Browse code

Added -t option, because I trace all the time. Fix problems in cmake and configure (freshly introduced in 0.9)

Nat! authored on 15-10-2015 19:02:10
Showing 5 changed files
... ...
@@ -1,3 +1,7 @@
1
+0.9.1
2
+===
3
+   Fix cmake and configure build.
4
+
1 5
 0.9
2 6
 ===
3 7
    Specifying repos with mulle-bootstrap build <repos> was broken.
... ...
@@ -29,7 +29,7 @@
29 29
 #   ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
30 30
 #   POSSIBILITY OF SUCH DAMAGE.
31 31
 
32
-VERSION=0.9
32
+VERSION=0.9.1
33 33
 
34 34
 #
35 35
 # This is the main user interface to mulle-bootstrap
... ...
@@ -65,36 +65,46 @@ then
65 65
    shift
66 66
 fi
67 67
 
68
-if [ "$1" = "-v" ]
68
+if [ "$1" = "-t" ]
69 69
 then
70
-   if [ -z "${MULLE_BOOTSTRAP_TRACE}" ]
71
-   then
72
-      MULLE_BOOTSTRAP_TRACE="VERBOSE"
73
-      export MULLE_BOOTSTRAP_TRACE
74
-   fi
70
+   MULLE_BOOTSTRAP_TRACE="1848"
71
+   export MULLE_BOOTSTRAP_TRACE
72
+
75 73
    GITFLAGS="-v"
76 74
    export GITFLAGS
77 75
    shift
78 76
 else
79
-   if [ "$1" = "-V" ]
77
+   if [ "$1" = "-v" ]
80 78
    then
81 79
       if [ -z "${MULLE_BOOTSTRAP_TRACE}" ]
82 80
       then
83
-         MULLE_BOOTSTRAP_TRACE="ALL"
81
+         MULLE_BOOTSTRAP_TRACE="VERBOSE"
84 82
          export MULLE_BOOTSTRAP_TRACE
85 83
       fi
86 84
       GITFLAGS="-v"
87 85
       export GITFLAGS
88 86
       shift
89 87
    else
90
-      if [ "$1" = "-s" ] # silent
88
+      if [ "$1" = "-V" ]
91 89
       then
92
-         MULLE_BOOTSTRAP_TRACE=
93
-         MULLE_BOOTSTRAP_TERSE="YES"
94
-         export MULLE_BOOTSTRAP_TERSE
95
-         GITFLAGS="-q"
90
+         if [ -z "${MULLE_BOOTSTRAP_TRACE}" ]
91
+         then
92
+            MULLE_BOOTSTRAP_TRACE="ALL"
93
+            export MULLE_BOOTSTRAP_TRACE
94
+         fi
95
+         GITFLAGS="-v"
96 96
          export GITFLAGS
97 97
          shift
98
+      else
99
+         if [ "$1" = "-s" ] # silent
100
+         then
101
+            MULLE_BOOTSTRAP_TRACE=
102
+            MULLE_BOOTSTRAP_TERSE="YES"
103
+            export MULLE_BOOTSTRAP_TERSE
104
+            GITFLAGS="-q"
105
+            export GITFLAGS
106
+            shift
107
+         fi
98 108
       fi
99 109
    fi
100 110
 fi
... ...
@@ -103,7 +113,7 @@ fi
103 113
 usage()
104 114
 {
105 115
    cat <<EOF
106
-usage: mulle-bootstrap [-a|y][-n][-v|-s] [command] [--help]
116
+usage: mulle-bootstrap [-a|-y][-n][-v|-s|-t] [command] [--help]
107 117
        version ${VERSION}
108 118
 
109 119
  Specify the -h or --help option after each command to get more help.
... ...
@@ -111,9 +121,12 @@ usage: mulle-bootstrap [-a|y][-n][-v|-s] [command] [--help]
111 121
  Flags (-n must be first, if present)
112 122
    -a        : always chose default answer to questions
113 123
    -y        : always say yes to questions (scripts wont be checked)
124
+
114 125
    -n        : do nothing creative or destructive
126
+
115 127
    -v        : be more verbose (-V even more verbose)
116 128
    -s        : be more terse
129
+   -t        : turns on shell tracing for development
117 130
 
118 131
  Common user commands:
119 132
    bootstrap : does fetch and build recursively [default]
... ...
@@ -420,7 +420,7 @@ ${C_MAGENTA}${name}${C_INFO} for SDK ${C_MAGENTA}${sdk}${C_INFO} ..."
420 420
    logfile1="${BUILDLOG_SUBDIR}/${name}-${configuration}-${sdk}.cmake.log"
421 421
    logfile2="${BUILDLOG_SUBDIR}/${name}-${configuration}-${sdk}.make.log"
422 422
 
423
-   log_info "Build logs will be in ${C_WHITE}${logfile1}${C_INFO} and ${C_WHITE}${logfile2}{C_INFO}"
423
+   log_info "Build logs will be in ${C_WHITE}${logfile1}${C_INFO} and ${C_WHITE}${logfile2}${C_INFO}"
424 424
 
425 425
    owd="${PWD}"
426 426
    mkdir_if_missing "${builddir}"
... ...
@@ -431,8 +431,8 @@ ${C_MAGENTA}${name}${C_INFO} for SDK ${C_MAGENTA}${sdk}${C_INFO} ..."
431 431
       #
432 432
       set -f
433 433
 
434
-      logfile1="${owd}/${logfile}"
435
-      logfile2="${owd}/${logfile}"
434
+      logfile1="${owd}/${logfile1}"
435
+      logfile2="${owd}/${logfile2}"
436 436
       if [ "$MULLE_BOOTSTRAP_DRY_RUN" = "YES" ]
437 437
       then
438 438
          logfile1="/dev/null"
... ...
@@ -527,7 +527,7 @@ ${C_MAGENTA}${name}${C_INFO} for SDK ${C_MAGENTA}${sdk}${C_INFO} ..."
527 527
    logfile1="${BUILDLOG_SUBDIR}/${name}-${configuration}-${sdk}.configure.log"
528 528
    logfile2="${BUILDLOG_SUBDIR}/${name}-${configuration}-${sdk}.make.log"
529 529
 
530
-   log_info "Build logs will be in ${C_WHITE}${logfile1}${C_INFO} and ${C_WHITE}${logfile2}{C_INFO}"
530
+   log_info "Build logs will be in ${C_WHITE}${logfile1}${C_INFO} and ${C_WHITE}${logfile2}${C_INFO}"
531 531
 
532 532
    owd="${PWD}"
533 533
    mkdir_if_missing "${builddir}"
... ...
@@ -535,8 +535,8 @@ ${C_MAGENTA}${name}${C_INFO} for SDK ${C_MAGENTA}${sdk}${C_INFO} ..."
535 535
 
536 536
        set -f
537 537
 
538
-      logfile1="${owd}/${logfile}"
539
-      logfile2="${owd}/${logfile}"
538
+      logfile1="${owd}/${logfile1}"
539
+      logfile2="${owd}/${logfile2}"
540 540
       if [ "$MULLE_BOOTSTRAP_DRY_RUN" = "YES" ]
541 541
       then
542 542
          logfile1="/dev/null"
... ...
@@ -521,6 +521,11 @@ ensure_clones_directory()
521 521
       fi
522 522
       mkdir_if_missing "${CLONES_FETCH_SUBDIR}"
523 523
    fi
524
+
525
+   if [ -d "${BOOTSTRAP_SUBDIR}.auto" ]
526
+   then
527
+      log_warning "Folder ${C_WHITE}${BOOTSTRAP_SUBDIR}.auto${C_WARNING} already exists!"
528
+   fi
524 529
 }
525 530
 
526 531
 
... ...
@@ -115,12 +115,12 @@ internal_fail()
115 115
 
116 116
 eval_exekutor()
117 117
 {
118
-   if [ "$MULLE_BOOTSTRAP_DRY_RUN" = "YES" -o "$MULLE_BOOTSTRAP_TRACE" = "YES" ]
118
+   if [ "${MULLE_BOOTSTRAP_DRY_RUN}" = "YES" -o "${MULLE_BOOTSTRAP_TRACE}" = "YES" ]
119 119
    then
120 120
       echo "$@" >&2
121 121
    fi
122 122
 
123
-   if [ "$MULLE_BOOTSTRAP_DRY_RUN" != "YES" ]
123
+   if [ "${MULLE_BOOTSTRAP_DRY_RUN}" != "YES" ]
124 124
    then
125 125
       eval "$@"
126 126
    fi
... ...
@@ -136,12 +136,12 @@ logging_eval_exekutor()
136 136
 
137 137
 exekutor()
138 138
 {
139
-   if [ "$MULLE_BOOTSTRAP_DRY_RUN" = "YES" -o "$MULLE_BOOTSTRAP_TRACE" = "YES" ]
139
+   if [ "${MULLE_BOOTSTRAP_DRY_RUN}" = "YES" -o "${MULLE_BOOTSTRAP_TRACE}" = "YES" ]
140 140
    then
141 141
       echo "$@" >&2
142 142
    fi
143 143
 
144
-   if [ "$MULLE_BOOTSTRAP_DRY_RUN" != "YES" ]
144
+   if [ "${MULLE_BOOTSTRAP_DRY_RUN}" != "YES" ]
145 145
    then
146 146
       "$@"
147 147
    fi