From 13abd0950400b43a2bb7064dadb2f30a94ee32fd Mon Sep 17 00:00:00 2001
From: Timothy Pearson <kb9vqf@pearsoncomputing.net>
Date: Tue, 31 Jan 2012 00:33:28 -0600
Subject: Fix FTBFS

---
 qtinterface/CMakeLists.txt            |  2 +-
 qtinterface/interface_qt3/tmoc.cmake  | 21 +++++++++++++++++++++
 qtinterface/interface_tqt3/tmoc.cmake | 21 +++++++++++++++++++++
 qtinterface/tmoc.cmake                | 21 ---------------------
 4 files changed, 43 insertions(+), 22 deletions(-)
 create mode 100755 qtinterface/interface_qt3/tmoc.cmake
 create mode 100755 qtinterface/interface_tqt3/tmoc.cmake
 delete mode 100755 qtinterface/tmoc.cmake

diff --git a/qtinterface/CMakeLists.txt b/qtinterface/CMakeLists.txt
index fc18981..c50bf1f 100644
--- a/qtinterface/CMakeLists.txt
+++ b/qtinterface/CMakeLists.txt
@@ -109,7 +109,7 @@ install(
 
 ##### tqt tools #################################
 
-configure_file( tmoc.cmake tmoc @ONLY )
+configure_file( ${IFACE}/tmoc.cmake tmoc @ONLY )
 if ( NOT HAVE_REAL_TQT )
   configure_file( tqt-replace.cmake tqt-replace @ONLY )
   configure_file( tqt-replace-stream.cmake tqt-replace-stream @ONLY )
diff --git a/qtinterface/interface_qt3/tmoc.cmake b/qtinterface/interface_qt3/tmoc.cmake
new file mode 100755
index 0000000..087fbdb
--- /dev/null
+++ b/qtinterface/interface_qt3/tmoc.cmake
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+#
+# Very simple moc wrapper, for using with cmake
+#
+
+if [ -f @BIN_INSTALL_DIR@/tqt-replace-stream ]; then
+	if [ -z "$1" ]; then
+		echo "Usage: tmoc <input_file> -o <out_file>"
+	else
+		input_file="$1"
+		out_file="$3"
+		@BIN_INSTALL_DIR@/tqt-replace-stream "${input_file}" | \
+	        @MOC_EXECUTABLE@ | \
+	        sed "/#include <qmetaobject.h>/ i #undef QT_NO_COMPAT\n#include \"${input_file}\"" \
+		> "${out_file}"
+	fi
+else
+	echo "ERROR: @BIN_INSTALL_DIR@/tqt-replace-stream is not available.  tmoc will fail!"
+	exit 1;
+fi
diff --git a/qtinterface/interface_tqt3/tmoc.cmake b/qtinterface/interface_tqt3/tmoc.cmake
new file mode 100755
index 0000000..8c7cfcc
--- /dev/null
+++ b/qtinterface/interface_tqt3/tmoc.cmake
@@ -0,0 +1,21 @@
+#!/bin/bash
+
+#
+# Very simple moc wrapper, for using with cmake
+#
+
+if [ -f @BIN_INSTALL_DIR@/tqt-replace-stream ]; then
+	if [ -z "$1" ]; then
+		echo "Usage: tmoc <input_file> -o <out_file>"
+	else
+		input_file="$1"
+		out_file="$3"
+		@BIN_INSTALL_DIR@/tqt-replace-stream "${input_file}" | \
+	        @MOC_EXECUTABLE@ | \
+	        sed "/#include <ntqmetaobject.h>/ i #undef QT_NO_COMPAT\n#include \"${input_file}\"" \
+		> "${out_file}"
+	fi
+else
+	echo "ERROR: @BIN_INSTALL_DIR@/tqt-replace-stream is not available.  tmoc will fail!"
+	exit 1;
+fi
diff --git a/qtinterface/tmoc.cmake b/qtinterface/tmoc.cmake
deleted file mode 100755
index 8c7cfcc..0000000
--- a/qtinterface/tmoc.cmake
+++ /dev/null
@@ -1,21 +0,0 @@
-#!/bin/bash
-
-#
-# Very simple moc wrapper, for using with cmake
-#
-
-if [ -f @BIN_INSTALL_DIR@/tqt-replace-stream ]; then
-	if [ -z "$1" ]; then
-		echo "Usage: tmoc <input_file> -o <out_file>"
-	else
-		input_file="$1"
-		out_file="$3"
-		@BIN_INSTALL_DIR@/tqt-replace-stream "${input_file}" | \
-	        @MOC_EXECUTABLE@ | \
-	        sed "/#include <ntqmetaobject.h>/ i #undef QT_NO_COMPAT\n#include \"${input_file}\"" \
-		> "${out_file}"
-	fi
-else
-	echo "ERROR: @BIN_INSTALL_DIR@/tqt-replace-stream is not available.  tmoc will fail!"
-	exit 1;
-fi
-- 
cgit v1.2.3

