| | 322 | if [ -n "$CC_COMPAT" ]; then |
|---|
| | 323 | if check_avail "$CC_COMPAT" CC_COMPAT really; then |
|---|
| | 324 | cc_compat_ver=`$CC_COMPAT -dumpversion` 2>/dev/null |
|---|
| | 325 | if [ $? -ne 0 ]; then |
|---|
| | 326 | log_failure "cannot execute '$CC_COMPAT -dumpversion'" |
|---|
| | 327 | fail really |
|---|
| | 328 | fi |
|---|
| | 329 | cc_compat_maj=`echo $cc_compat_ver|cut -d. -f1` |
|---|
| | 330 | cc_compat_min=`echo $cc_compat_ver|cut -d. -f2` |
|---|
| | 331 | if [ $cc_compat_maj -lt 3 \ |
|---|
| | 332 | -o \( $cc_compat_maj -eq 3 -a $cc_compat_min -lt 2 \) \ |
|---|
| | 333 | -o \( $cc_compat_maj -eq 4 -a $cc_compat_min -lt 1 \) \ |
|---|
| | 334 | -o \( $cc_compat_maj -eq 4 -a $cc_compat_min -gt 2 \) \ |
|---|
| | 335 | -o $cc_compat_maj -gt 4 ]; then |
|---|
| | 336 | log "" |
|---|
| | 337 | log " ** Version $cc_compat_ver of the compatibility gcc found. Expected gcc 3.x with x>1" |
|---|
| | 338 | log " ** or gcc 4.x with 0<x<3" |
|---|
| | 339 | fail really |
|---|
| | 340 | fi |
|---|
| | 341 | cnf_append "VBOX_RECOMPILER_OP_GCC" "$CC_COMPAT" |
|---|
| | 342 | fi |
|---|
| | 343 | fi |
|---|
| 349 | | fi |
|---|
| 350 | | if check_avail "$CC_COMPAT" CC_COMPAT really; then |
|---|
| 351 | | cc_compat_ver=`$CC_COMPAT -dumpversion` 2>/dev/null |
|---|
| 352 | | if [ $? -ne 0 ]; then |
|---|
| 353 | | log_failure "cannot execute '$CC_COMPAT -dumpversion'" |
|---|
| 354 | | fail really |
|---|
| 355 | | fi |
|---|
| 356 | | cc_compat_maj=`echo $cc_compat_ver|cut -d. -f1` |
|---|
| 357 | | cc_compat_min=`echo $cc_compat_ver|cut -d. -f2` |
|---|
| 358 | | if [ $cc_compat_maj -lt 3 \ |
|---|
| 359 | | -o \( $cc_compat_maj -eq 3 -a $cc_compat_min -lt 2 \) \ |
|---|
| 360 | | -o \( $cc_compat_maj -eq 4 -a $cc_compat_min -lt 1 \) \ |
|---|
| 361 | | -o \( $cc_compat_maj -eq 4 -a $cc_compat_min -gt 2 \) \ |
|---|
| 362 | | -o $cc_compat_maj -gt 4 ]; then |
|---|
| 363 | | log "" |
|---|
| 364 | | log " ** Version $cc_compat_ver of the compatibility gcc found. Expected gcc 3.x with x>1" |
|---|
| 365 | | log " ** or gcc 4.x with 0<x<3" |
|---|
| 366 | | fail really |
|---|
| 367 | | fi |
|---|
| 368 | | cnf_append "VBOX_RECOMPILER_OP_GCC" "$CC_COMPAT" |
|---|