Index: libcfa/configure
===================================================================
--- libcfa/configure	(revision a5121bff2d239413034fc4cc466f9e5b15eebd1b)
+++ libcfa/configure	(revision fc846ae1acddff210b81091b8b89c32961a0002c)
@@ -623,4 +623,6 @@
 CFA_PREFIX
 CFA_NAME
+CONFIG_CFAFLAGS
+CONFIG_CFLAGS
 ARCH_FLAGS
 CFACPP
@@ -629,8 +631,4 @@
 CONFIGURATION
 ARCHITECTURE
-AM_BACKSLASH
-AM_DEFAULT_VERBOSITY
-AM_DEFAULT_V
-AM_V
 am__untar
 am__tar
@@ -656,4 +654,8 @@
 INSTALL_SCRIPT
 INSTALL_PROGRAM
+AM_BACKSLASH
+AM_DEFAULT_VERBOSITY
+AM_DEFAULT_V
+AM_V
 target_alias
 host_alias
@@ -1910,4 +1912,43 @@
 
 
+# Check whether --enable-silent-rules was given.
+if test "${enable_silent_rules+set}" = set; then :
+  enableval=$enable_silent_rules;
+fi
+
+case $enable_silent_rules in # (((
+  yes) AM_DEFAULT_VERBOSITY=0;;
+   no) AM_DEFAULT_VERBOSITY=1;;
+    *) AM_DEFAULT_VERBOSITY=0;;
+esac
+am_make=${MAKE-make}
+{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
+$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
+if ${am_cv_make_support_nested_variables+:} false; then :
+  $as_echo_n "(cached) " >&6
+else
+  if $as_echo 'TRUE=$(BAR$(V))
+BAR0=false
+BAR1=true
+V=1
+am__doit:
+	@$(TRUE)
+.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
+  am_cv_make_support_nested_variables=yes
+else
+  am_cv_make_support_nested_variables=no
+fi
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
+$as_echo "$am_cv_make_support_nested_variables" >&6; }
+if test $am_cv_make_support_nested_variables = yes; then
+    AM_V='$(V)'
+  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
+else
+  AM_V=$AM_DEFAULT_VERBOSITY
+  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
+fi
+AM_BACKSLASH='\'
+
 
 
@@ -2343,43 +2384,4 @@
 rmdir .tst 2>/dev/null
 
-# Check whether --enable-silent-rules was given.
-if test "${enable_silent_rules+set}" = set; then :
-  enableval=$enable_silent_rules;
-fi
-
-case $enable_silent_rules in # (((
-  yes) AM_DEFAULT_VERBOSITY=0;;
-   no) AM_DEFAULT_VERBOSITY=1;;
-    *) AM_DEFAULT_VERBOSITY=1;;
-esac
-am_make=${MAKE-make}
-{ $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $am_make supports nested variables" >&5
-$as_echo_n "checking whether $am_make supports nested variables... " >&6; }
-if ${am_cv_make_support_nested_variables+:} false; then :
-  $as_echo_n "(cached) " >&6
-else
-  if $as_echo 'TRUE=$(BAR$(V))
-BAR0=false
-BAR1=true
-V=1
-am__doit:
-	@$(TRUE)
-.PHONY: am__doit' | $am_make -f - >/dev/null 2>&1; then
-  am_cv_make_support_nested_variables=yes
-else
-  am_cv_make_support_nested_variables=no
-fi
-fi
-{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $am_cv_make_support_nested_variables" >&5
-$as_echo "$am_cv_make_support_nested_variables" >&6; }
-if test $am_cv_make_support_nested_variables = yes; then
-    AM_V='$(V)'
-  AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
-else
-  AM_V=$AM_DEFAULT_VERBOSITY
-  AM_DEFAULT_V=$AM_DEFAULT_VERBOSITY
-fi
-AM_BACKSLASH='\'
-
 if test "`cd $srcdir && pwd`" != "`pwd`"; then
   # Use -I$(srcdir) only when $(srcdir) != ., so that make's output
@@ -2498,4 +2500,7 @@
 
 
+# don't use the default CFLAGS as they unconditonnaly add -O2
+: ${CFLAGS=""}
+
 # Allow program name tansformation
 # will fill program_transform_name with appropriate sed regex
@@ -2511,4 +2516,6 @@
 
 
+#==============================================================================
+#Handle specific flags
 case $ARCHITECTURE in
 	"x64"        ) ARCH_FLAGS="-m64";;
@@ -2516,4 +2523,22 @@
 	"arm"        ) ARCH_FLAGS="";;
 esac
+
+
+
+case $CONFIGURATION in
+	"debug"   )
+		CONFIG_CFLAGS="-O0 -g"
+		CONFIG_CFAFLAGS="-debug"
+	;;
+	"nodebug" )
+		CONFIG_CFLAGS="-O2 -s"
+		CONFIG_CFAFLAGS="-nodebug"
+	;;
+	"nolib"   )
+		CONFIG_CFLAGS=""
+		CONFIG_CFAFLAGS=""
+	;;
+esac
+
 
 
