Index: src/fla/Makefile
===================================================================
--- src/fla/Makefile	(revision 5f4d9c3b32eea7b6643a751aa75bdb05b7d41576)
+++ src/fla/Makefile	(revision 5f4d9c3b32eea7b6643a751aa75bdb05b7d41576)
@@ -0,0 +1,25 @@
+include ../../config.mak
+
+ifeq ($(BUILD_STATIC), yes)
+  LDFLAGS += -static
+endif
+
+CFLAGS +=-O2 
+
+fla: 
+	$(CC) $(CFLAGS) fla.c -o fla $(LDFLAGS)
+
+.PHONY: install
+install:
+ifdef BIN_DIR
+	install -m 0755 fla $(BIN_DIR)
+endif
+
+.PHONY: uninstall
+uninstall:
+ifdef BIN_DIR
+	rm $(BIN_DIR)/fla
+endif
+
+clean: 
+	rm fla || true
Index: src/fla/fla.c
===================================================================
--- src/fla/fla.c	(revision 5f4d9c3b32eea7b6643a751aa75bdb05b7d41576)
+++ src/fla/fla.c	(revision 5f4d9c3b32eea7b6643a751aa75bdb05b7d41576)
@@ -0,0 +1,68 @@
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+#include <regex.h>
+
+char buf[5000];
+
+int main(int argc, char **argv)
+{
+
+  char *pattern;
+  char eoln;
+  regex_t re;
+
+  int firstline = 1;
+
+  if( argc < 2 )
+  {
+/*     pattern="[ \t]*([0-9]+[ \t]+){2}EOS([ \t].*)?"; */
+    pattern = "[ \t]*BOS([ \t].*)?";
+  }
+  else
+  {
+    pattern = argv[1];
+  }
+
+  if( argc < 3 )
+  {
+    eoln = '\f';
+  }
+  else
+  {
+    eoln = atoi(argv[2]);
+  }
+
+  if( 0 != regcomp(&re, pattern, REG_EXTENDED|REG_NOSUB) )
+  {
+    fprintf(stderr, "Invalid pattern.\n");
+    return 1;
+  }
+
+  while( fgets(buf, 5000, stdin) )
+  {
+    buf[strlen(buf)-1] = '\0';
+    if( firstline )
+    {
+      firstline = 0;
+    }
+    else
+    {
+      if( 0 == regexec(&re, buf, (size_t)0, NULL, 0) )
+      {
+        putchar('\n');
+      }
+      else
+      {
+        putchar(eoln);
+      }
+    }
+    fputs(buf, stdout);
+  }
+
+  putchar('\n');
+
+  return 0;
+
+}
+
