diff --git a/applications/test/wmake1/Test-wmake1.C b/applications/test/wmake1/Test-wmake1.C
index 614d9189fb8e2c9964383340c2c7b0f7330ae0b1..ac3469c2049a1ab468dd7b8ac9003c31f21bd696 100644
--- a/applications/test/wmake1/Test-wmake1.C
+++ b/applications/test/wmake1/Test-wmake1.C
@@ -47,6 +47,12 @@ int main(int argc, char *argv[])
 {
     printTest();
 
+    #ifdef FULLDEBUG
+    Info<< nl << "Compiled with FULLDEBUG" << nl;
+    #else
+    Info<< nl << "Regular compilation" << nl;
+    #endif
+
     Info<< "\nEnd\n" << nl;
 
     return 0;
diff --git a/wmake/scripts/AllwmakeParseArguments b/wmake/scripts/AllwmakeParseArguments
index abe92d94d0c0f68d645d5da3b9f1f0a02d9dbf6c..ddbf07c0704a7180a5ae0c99ed8f05d5913fd3dc 100644
--- a/wmake/scripts/AllwmakeParseArguments
+++ b/wmake/scripts/AllwmakeParseArguments
@@ -53,7 +53,7 @@ USAGE
 # Parse the arguments and options
 #------------------------------------------------------------------------------
 
-unset fromWmake optLog optQueue
+unset fromWmake optDebug optLog optQueue
 
 for arg in "$@"
 do
@@ -88,8 +88,12 @@ do
         fi
         continue    # Permanently remove arg
         ;;
+    -debug)
+        optDebug="-debug"
+        continue    # Permanently remove arg
+        ;;
     -q | -queue)
-        optQueue="-q"
+        optQueue="-queue"
         continue    # Permanently remove arg
         ;;
     lib | libo | libso | dep | objects)
@@ -116,7 +120,7 @@ then
     else
         echo "Logging wmake -all output to '$optLog'" 1>&2
         echo 1>&2
-        exec wmake -all $optQueue $* 2>&1 | /usr/bin/tee $optLog
+        exec wmake -all $optDebug $optQueue $* 2>&1 | /usr/bin/tee $optLog
         # Need to cleanup after the tee
         rc=$? # Error code from tee (not wmake), but not entirely important
         echo "Done logging to '$optLog'" 1>&2
@@ -139,7 +143,7 @@ fi
 # Cleanup local variables and functions
 #------------------------------------------------------------------------------
 
-unset fromWmake optLog optQueue
+unset fromWmake optDebug optLog optQueue
 unset -f usage
 
 
diff --git a/wmake/wmake b/wmake/wmake
index 65dc6282dca4cb1aaf0f7ce30c659ef10bcdda01..27c0d559890e4c22f7f47289ebdf194f27e5dee7 100755
--- a/wmake/wmake
+++ b/wmake/wmake
@@ -71,6 +71,7 @@ options:
   -a | -all         wmake all sub-directories, running Allwmake if present
   -q | -queue       wmakeCollect all sub-directories, running Allwmake if present
   -k | -keep-going  Keep going even when errors occur (-non-stop)
+  -debug            Define c++DBUG='-DFULLDEBUG -g -O0' as override
   -j                Compile using all local cores/hyperthreads
   -jN | -j N        Compile using N cores/hyperthreads
   -no-scheduler     Disable scheduled parallel compilation
@@ -131,7 +132,7 @@ allCores()
 #------------------------------------------------------------------------------
 
 # Default to compiling the local target only
-unset all optShow update optPrintRootDir
+unset all update optDebug optShow optPrintRootDir
 
 while [ "$#" -gt 0 ]
 do
@@ -143,6 +144,9 @@ do
         -s | -silent)
             export WM_QUIET=true
             ;;
+        -debug)
+            optDebug="-DFULLDEBUG -g -O0"
+            ;;
         -show-api | -show-ext-so | \
         -show-compile-c | -show-c | -show-cflags | -show-cflags-arch | \
         -show-compile-cxx | -show-cxx | -show-cxxflags | -show-cxxflags-arch )
@@ -348,7 +352,7 @@ if [ "$all" = all ]
 then
     if [ -e Allwmake ]
     then
-        ./Allwmake -fromWmake $targetType
+        ./Allwmake -fromWmake ${optDebug:+-debug} $targetType
         exit $?
     fi
 
@@ -364,6 +368,7 @@ then
         # Compile all applications in sub-directories
         $make ${WM_CONTINUE_ON_ERROR:+-k} \
               -f $WM_DIR/makefiles/apps \
+              ${optDebug:+c++DBUG="$optDebug"} \
               TARGET="$targetType" FOAM_APPS="$FOAM_APPS"
         makeExitCode=$?
     else
@@ -394,7 +399,7 @@ then
         "$WM_SCHEDULER" -clean \
      && wmake -all objects   \
      && "$WM_SCHEDULER"
-    ) && wmake -all
+    ) && wmake -all ${optDebug:+-debug}
     exit $?
 fi
 
@@ -449,11 +454,11 @@ esac
 
     # Pre-build the $WM_OPTIONS/options file
     # which is included when building the $WM_OPTIONS/files file
-    $make -s -f $WM_DIR/makefiles/files MAKE_DIR=$MakeDir \
-          OBJECTS_DIR=$objectsDir $objectsDir/options
+    $make -s -f $WM_DIR/makefiles/files \
+        MAKE_DIR=$MakeDir OBJECTS_DIR=$objectsDir $objectsDir/options
 
-    $make -s -f $WM_DIR/makefiles/files MAKE_DIR=$MakeDir \
-          OBJECTS_DIR=$objectsDir
+    $make -s -f $WM_DIR/makefiles/files \
+        MAKE_DIR=$MakeDir OBJECTS_DIR=$objectsDir
 )
 
 
@@ -477,8 +482,8 @@ case "$targetType" in
 (lib | libo | libso | dep)
     if grep -qe '^ *LIB *=' "$MakeDir/files" 2>/dev/null
     then
-        $make -s -f $WM_DIR/makefiles/general MAKE_DIR=$MakeDir \
-              OBJECTS_DIR=$objectsDir lnInclude
+        $make -s -f $WM_DIR/makefiles/general \
+            MAKE_DIR=$MakeDir OBJECTS_DIR=$objectsDir lnInclude
     fi
     ;;
 esac
@@ -491,8 +496,8 @@ esac
 if [ -n "$WM_UPDATE_DEPENDENCIES" ]
 then
 
-    $make -f $WM_DIR/makefiles/general MAKE_DIR=$MakeDir \
-        OBJECTS_DIR=$objectsDir updatedep
+    $make -f $WM_DIR/makefiles/general \
+        MAKE_DIR=$MakeDir OBJECTS_DIR=$objectsDir updatedep
     makeExitCode=$?
 
     [ $makeExitCode -eq 0 ] || exit $makeExitCode
@@ -503,8 +508,9 @@ fi
 # Make the dependency files or object files and link
 #------------------------------------------------------------------------------
 
-exec $make -f $WM_DIR/makefiles/general MAKE_DIR=$MakeDir \
-     OBJECTS_DIR=$objectsDir $targetType
+exec $make -f $WM_DIR/makefiles/general \
+     ${optDebug:+c++DBUG="$optDebug"} \
+     MAKE_DIR=$MakeDir OBJECTS_DIR=$objectsDir $targetType
 
 exit 0 # clean exit