This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

excluding flags from build, part II



Actually, once I figured out tcl's quoting scheme, the general case
isn't any harder than the specific case I was solving.   Quick testing
shows this works...

$ diff -c target.exp_ target.exp
*** target.exp_ Mon Jun 29 23:20:03 1998
--- target.exp Sat Jul 18 23:38:22 1998
***************
*** 405,410 ****
      if [board_info $dest exists multilib_flags] {
        append add_flags " [board_info $dest multilib_flags]";
      }

      verbose "doing compile"
      set sources ""
--- 406,419 ----
      if [board_info $dest exists multilib_flags] {
        append add_flags " [board_info $dest multilib_flags]";
      }
+
+    if [board_info $dest exists exclude_from_build] {
+      if [regexp -- [board_info $dest exclude_from_build]  $add_flags] {
+      send_user "**** $add_flags\n"
+          unsupported "[board_info $dest exclude_from_build] is not supported"
+       return
+       }
+    }

      verbose "doing compile"
      set sources ""


Then this lets you specify a regex in the baseboards/unix.exp (or whatever)
to allow you to exclude certain compiles...

if [regexp -- "-mcoff" [board_info $board multilib_flags]] {
        set_board_info exclude_from_build (-fPIC|-fpic)
}


RJL

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]