Index: kernel/generic/include/proc/thread.h
===================================================================
--- kernel/generic/include/proc/thread.h	(revision df58e448060bb6d63ea118d30cb9b3b9b8c059bf)
+++ kernel/generic/include/proc/thread.h	(revision 88743b50b604d7ae773de9d961b292bb34a37cc7)
@@ -140,10 +140,4 @@
 	bool interrupted;
 	
-	/**
-	 * If true, the scheduler will print a stack trace
-	 * to the kernel console upon scheduling this thread.
-	 */
-	bool btrace;
-	
 	/** If true, thread_join_timeout() cannot be used on this thread. */
 	bool detached;
@@ -196,4 +190,10 @@
 	
 #ifdef CONFIG_UDEBUG
+	/**
+	 * If true, the scheduler will print a stack trace
+	 * to the kernel console upon scheduling this thread.
+	 */
+	bool btrace;
+	
 	/** Debugging stuff */
 	udebug_thread_t udebug;
@@ -245,5 +245,8 @@
 extern void thread_update_accounting(bool);
 extern bool thread_exists(thread_t *);
+
+#ifdef CONFIG_UDEBUG
 extern void thread_stack_trace(thread_id_t);
+#endif
 
 /** Fpu context slab cache. */
