more gcc-3.1 troubles (and fix ;-)



Metacity doesn't seem to like gcc-3.1 on my YellowDog-2.2:

workspace.c: In function `meta_workspace_index':
workspace.c:244: warning: control reaches end of non-void function
workspace.c: In function `meta_workspace_screen_index':
workspace.c:268: warning: control reaches end of non-void function
workspace.c: In function `calc_rows_and_cols':
workspace.c:560: unrecognizable insn:
(insn 148 57 149 (parallel[
            (set (reg/v:SI 11 r11 [120])
                (plus:SI (gt:SI (reg:SI 0 r0 [141])
                        (const_int 0 [0x0]))
                    (reg:SI 9 r9 [134])))
            (clobber (reg:SI 8 r8))
        ] ) -1 (nil)
    (nil))
workspace.c:560: Internal compiler error in extract_insn, at recog.c:2132
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://www.gnu.org/software/gcc/bugs.html> for instructions.
make[4]: *** [workspace.o] Error 1
make[4]: Leaving directory `/home/robert/download/garnome-0.12.0/gnome/metacity/work/metacity-2.3.987/src'
make[3]: *** [all-recursive] Error 1
make[3]: Leaving directory `/home/robert/download/garnome-0.12.0/gnome/metacity/work/metacity-2.3.987/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/robert/download/garnome-0.12.0/gnome/metacity/work/metacity-2.3.987'
make[1]: *** [all-recursive-am] Error 2
make[1]: Leaving directory `/home/robert/download/garnome-0.12.0/gnome/metacity/work/metacity-2.3.987'
make: *** [build-work/metacity-2.3.987/Makefile] Error 2
[robert localhost metacity]$


I played around a little with the code around line 560 and by chance it suddenly worked for me. diff attached - however I'm not a guru at making diffs so I try to describe it too: just use *r and *c instead of int rows, cols in the whole funtion calc_rows_and_cols()

Other than that I'm halfway through compiling.
Great thanks everybody who contributed to gnome!

Robert
542,545c542,545
<   *r = screen->rows_of_workspaces;
<   *c = screen->columns_of_workspaces;
<   if (*r <= 0 && *c <= 0)
<     *c = num_workspaces;
---
>   rows = screen->rows_of_workspaces;
>   cols = screen->columns_of_workspaces;
>   if (rows <= 0 && cols <= 0)
>     cols = num_workspaces;
547,550c547,550
<   if (*r <= 0)
<     *r = num_workspaces / *c + ((num_workspaces % *c) > 0 ? 1 : 0);
<   if (*c <= 0)
<     *c = num_workspaces / *r + ((num_workspaces % *r) > 0 ? 1 : 0);
---
>   if (rows <= 0)
>     rows = num_workspaces / cols + ((num_workspaces % cols) > 0 ? 1 : 0);
>   if (cols <= 0)
>     cols = num_workspaces / rows + ((num_workspaces % rows) > 0 ? 1 : 0);
553,557c553,557
<   if (*r < 1)
<     *r = 1;
<   if (*c < 1)
<     *c = 1;
< /*
---
>   if (rows < 1)
>     rows = 1;
>   if (cols < 1)
>     cols = 1;
> 
560d559
< */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]