[Cmake-commits] CMake branch, next, updated. v2.8.6-1977-ga4d3147

Alexander Neundorf neundorf at kde.org
Tue Nov 22 13:27:22 EST 2011


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "CMake".

The branch, next has been updated
       via  a4d31477cfb1cc371e5d7387d742dbe6df838005 (commit)
       via  e8b5b222b6827e8db490bcc78ea9f967b5c4b247 (commit)
       via  69ac7cab9dad260a9feee00caea1813b5b76ebf5 (commit)
       via  a364dfbc83979d556848b1e54b2c637cfbdabb46 (commit)
      from  ddf16039f8f093f4d5aa43405ae1c22668b5246a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a4d31477cfb1cc371e5d7387d742dbe6df838005
commit a4d31477cfb1cc371e5d7387d742dbe6df838005
Merge: ddf1603 e8b5b22
Author:     Alexander Neundorf <neundorf at kde.org>
AuthorDate: Tue Nov 22 13:27:19 2011 -0500
Commit:     CMake Topic Stage <kwrobot at kitware.com>
CommitDate: Tue Nov 22 13:27:19 2011 -0500

    Merge topic 'RestoreAutmocKDECompatibility' into next
    
    e8b5b22 automoc: add test for including a moc_abc_p.cpp file
    69ac7ca automoc: add test for including the moc file from another header
    a364dfb automoc: add a test for including both abc.moc and moc_abc.cpp


http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=e8b5b222b6827e8db490bcc78ea9f967b5c4b247
commit e8b5b222b6827e8db490bcc78ea9f967b5c4b247
Author:     Alex Neundorf <neundorf at kde.org>
AuthorDate: Tue Nov 22 19:24:39 2011 +0100
Commit:     Alex Neundorf <neundorf at kde.org>
CommitDate: Tue Nov 22 19:24:39 2011 +0100

    automoc: add test for including a moc_abc_p.cpp file
    
    Alex

diff --git a/Tests/QtAutomoc/abc.cpp b/Tests/QtAutomoc/abc.cpp
index 25071cd..4bbc769 100644
--- a/Tests/QtAutomoc/abc.cpp
+++ b/Tests/QtAutomoc/abc.cpp
@@ -13,6 +13,7 @@
 
 
 #include "abc.h"
+#include "abc_p.h"
 
 #include <stdio.h>
 
@@ -35,11 +36,14 @@ void Abc::doAbc()
 {
   PrintAbc pa;
   pa.print();
+  AbcP abcP;
+  abcP.doAbcP();
 }
 
 // check that including the moc file for the cpp file and the header works:
 #include "abc.moc"
 #include "moc_abc.cpp"
+#include "moc_abc_p.cpp"
 
 // check that including a moc file from another header works:
 #include "moc_xyz.cpp"
diff --git a/Tests/QtAutomoc/abc.cpp b/Tests/QtAutomoc/abc_p.h
similarity index 62%
copy from Tests/QtAutomoc/abc.cpp
copy to Tests/QtAutomoc/abc_p.h
index 25071cd..952fff3 100644
--- a/Tests/QtAutomoc/abc.cpp
+++ b/Tests/QtAutomoc/abc_p.h
@@ -11,35 +11,20 @@
   See the License for more information.
 ============================================================================*/
 
+#ifndef ABC_P_H
+#define ABC_P_H
 
-#include "abc.h"
+#include <QObject>
 
 #include <stdio.h>
 
-class PrintAbc : public QObject
+class AbcP : public QObject
 {
   Q_OBJECT
   public:
-    PrintAbc():QObject() {}
+    AbcP() {}
   public slots:
-    void print() const { printf("abc\n"); }
+    void doAbcP() { printf("I am private abc !\n"); }
 };
 
-Abc::Abc()
-:QObject()
-{
-}
-
-
-void Abc::doAbc()
-{
-  PrintAbc pa;
-  pa.print();
-}
-
-// check that including the moc file for the cpp file and the header works:
-#include "abc.moc"
-#include "moc_abc.cpp"
-
-// check that including a moc file from another header works:
-#include "moc_xyz.cpp"
+#endif

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=69ac7cab9dad260a9feee00caea1813b5b76ebf5
commit 69ac7cab9dad260a9feee00caea1813b5b76ebf5
Author:     Alex Neundorf <neundorf at kde.org>
AuthorDate: Tue Nov 22 19:19:31 2011 +0100
Commit:     Alex Neundorf <neundorf at kde.org>
CommitDate: Tue Nov 22 19:19:31 2011 +0100

    automoc: add test for including the moc file from another header
    
    including moc_xyz.cpp in abc.cpp should run moc on xyz.h (and
    include the file in abc.cpp)
    
    Alex

diff --git a/Tests/QtAutomoc/CMakeLists.txt b/Tests/QtAutomoc/CMakeLists.txt
index c81ac11..9f02618 100644
--- a/Tests/QtAutomoc/CMakeLists.txt
+++ b/Tests/QtAutomoc/CMakeLists.txt
@@ -13,7 +13,7 @@ add_definitions(-DFOO)
 # create an executable and a library target, both requiring automoc:
 add_library(codeeditorLib STATIC codeeditor.cpp)
 
-add_executable(foo main.cpp calwidget.cpp foo.cpp blub.cpp bar.cpp abc.cpp)
+add_executable(foo main.cpp calwidget.cpp foo.cpp blub.cpp bar.cpp abc.cpp xyz.cpp)
 
 set_target_properties(foo codeeditorLib PROPERTIES AUTOMOC TRUE)
 
diff --git a/Tests/QtAutomoc/abc.cpp b/Tests/QtAutomoc/abc.cpp
index f922615..25071cd 100644
--- a/Tests/QtAutomoc/abc.cpp
+++ b/Tests/QtAutomoc/abc.cpp
@@ -37,5 +37,9 @@ void Abc::doAbc()
   pa.print();
 }
 
+// check that including the moc file for the cpp file and the header works:
 #include "abc.moc"
 #include "moc_abc.cpp"
+
+// check that including a moc file from another header works:
+#include "moc_xyz.cpp"
diff --git a/Tests/QtAutomoc/main.cpp b/Tests/QtAutomoc/main.cpp
index 5414daf..7eb29a3 100644
--- a/Tests/QtAutomoc/main.cpp
+++ b/Tests/QtAutomoc/main.cpp
@@ -46,6 +46,7 @@
 #include "blub.h"
 #include "sub/bar.h"
 #include "abc.h"
+#include "xyz.h"
 
 int main(int argv, char **args)
 {
@@ -70,5 +71,8 @@ int main(int argv, char **args)
   Abc abc;
   abc.doAbc();
 
+  Xyz xyz;
+  xyz.doXyz();
+
   return app.exec();
 }
diff --git a/Tests/QtAutomoc/abc.cpp b/Tests/QtAutomoc/xyz.cpp
similarity index 70%
copy from Tests/QtAutomoc/abc.cpp
copy to Tests/QtAutomoc/xyz.cpp
index f922615..a3562a3 100644
--- a/Tests/QtAutomoc/abc.cpp
+++ b/Tests/QtAutomoc/xyz.cpp
@@ -12,30 +12,17 @@
 ============================================================================*/
 
 
-#include "abc.h"
+#include "xyz.h"
 
 #include <stdio.h>
 
-class PrintAbc : public QObject
-{
-  Q_OBJECT
-  public:
-    PrintAbc():QObject() {}
-  public slots:
-    void print() const { printf("abc\n"); }
-};
-
-Abc::Abc()
+Xyz::Xyz()
 :QObject()
 {
 }
 
 
-void Abc::doAbc()
+void Xyz::doXyz()
 {
-  PrintAbc pa;
-  pa.print();
+  printf("This is xyz !\n");
 }
-
-#include "abc.moc"
-#include "moc_abc.cpp"
diff --git a/Tests/QtAutomoc/abc.cpp b/Tests/QtAutomoc/xyz.h
similarity index 70%
copy from Tests/QtAutomoc/abc.cpp
copy to Tests/QtAutomoc/xyz.h
index f922615..8175d37 100644
--- a/Tests/QtAutomoc/abc.cpp
+++ b/Tests/QtAutomoc/xyz.h
@@ -11,31 +11,18 @@
   See the License for more information.
 ============================================================================*/
 
+#ifndef XYZ_H
+#define XYZ_H
 
-#include "abc.h"
+#include <QObject>
 
-#include <stdio.h>
-
-class PrintAbc : public QObject
+class Xyz : public QObject
 {
   Q_OBJECT
   public:
-    PrintAbc():QObject() {}
+    Xyz();
   public slots:
-    void print() const { printf("abc\n"); }
+    void doXyz();
 };
 
-Abc::Abc()
-:QObject()
-{
-}
-
-
-void Abc::doAbc()
-{
-  PrintAbc pa;
-  pa.print();
-}
-
-#include "abc.moc"
-#include "moc_abc.cpp"
+#endif

http://cmake.org/gitweb?p=cmake.git;a=commitdiff;h=a364dfbc83979d556848b1e54b2c637cfbdabb46
commit a364dfbc83979d556848b1e54b2c637cfbdabb46
Author:     Alex Neundorf <neundorf at kde.org>
AuthorDate: Tue Nov 22 19:13:03 2011 +0100
Commit:     Alex Neundorf <neundorf at kde.org>
CommitDate: Tue Nov 22 19:13:03 2011 +0100

    automoc: add a test for including both abc.moc and moc_abc.cpp
    
    Alex

diff --git a/Tests/QtAutomoc/CMakeLists.txt b/Tests/QtAutomoc/CMakeLists.txt
index 9540e52..c81ac11 100644
--- a/Tests/QtAutomoc/CMakeLists.txt
+++ b/Tests/QtAutomoc/CMakeLists.txt
@@ -13,7 +13,7 @@ add_definitions(-DFOO)
 # create an executable and a library target, both requiring automoc:
 add_library(codeeditorLib STATIC codeeditor.cpp)
 
-add_executable(foo main.cpp calwidget.cpp foo.cpp blub.cpp bar.cpp)
+add_executable(foo main.cpp calwidget.cpp foo.cpp blub.cpp bar.cpp abc.cpp)
 
 set_target_properties(foo codeeditorLib PROPERTIES AUTOMOC TRUE)
 
diff --git a/Tests/QtAutomoc/abc.cpp b/Tests/QtAutomoc/abc.cpp
new file mode 100644
index 0000000..f922615
--- /dev/null
+++ b/Tests/QtAutomoc/abc.cpp
@@ -0,0 +1,41 @@
+/*============================================================================
+  CMake - Cross Platform Makefile Generator
+  Copyright 2004-2011 Kitware, Inc.
+  Copyright 2011 Alexander Neundorf (neundorf at kde.org)
+
+  Distributed under the OSI-approved BSD License (the "License");
+  see accompanying file Copyright.txt for details.
+
+  This software is distributed WITHOUT ANY WARRANTY; without even the
+  implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+  See the License for more information.
+============================================================================*/
+
+
+#include "abc.h"
+
+#include <stdio.h>
+
+class PrintAbc : public QObject
+{
+  Q_OBJECT
+  public:
+    PrintAbc():QObject() {}
+  public slots:
+    void print() const { printf("abc\n"); }
+};
+
+Abc::Abc()
+:QObject()
+{
+}
+
+
+void Abc::doAbc()
+{
+  PrintAbc pa;
+  pa.print();
+}
+
+#include "abc.moc"
+#include "moc_abc.cpp"
diff --git a/Tests/QtAutomoc/abc.h b/Tests/QtAutomoc/abc.h
new file mode 100644
index 0000000..d1924b0
--- /dev/null
+++ b/Tests/QtAutomoc/abc.h
@@ -0,0 +1,28 @@
+/*============================================================================
+  CMake - Cross Platform Makefile Generator
+  Copyright 2004-2011 Kitware, Inc.
+  Copyright 2011 Alexander Neundorf (neundorf at kde.org)
+
+  Distributed under the OSI-approved BSD License (the "License");
+  see accompanying file Copyright.txt for details.
+
+  This software is distributed WITHOUT ANY WARRANTY; without even the
+  implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+  See the License for more information.
+============================================================================*/
+
+#ifndef ABC_H
+#define ABC_H
+
+#include <QObject>
+
+class Abc : public QObject
+{
+  Q_OBJECT
+  public:
+    Abc();
+  public slots:
+    void doAbc();
+};
+
+#endif
diff --git a/Tests/QtAutomoc/main.cpp b/Tests/QtAutomoc/main.cpp
index 58e2a19..5414daf 100644
--- a/Tests/QtAutomoc/main.cpp
+++ b/Tests/QtAutomoc/main.cpp
@@ -45,6 +45,7 @@
 #include "foo.h"
 #include "blub.h"
 #include "sub/bar.h"
+#include "abc.h"
 
 int main(int argv, char **args)
 {
@@ -66,5 +67,8 @@ int main(int argv, char **args)
   Bar bar;
   bar.doBar();
 
+  Abc abc;
+  abc.doAbc();
+
   return app.exec();
 }

-----------------------------------------------------------------------

Summary of changes:
 Tests/QtAutomoc/CMakeLists.txt       |    2 +-
 Tests/QtAutomoc/{foo.cpp => abc.cpp} |   28 +++++++++++++++++++---------
 Tests/QtAutomoc/{sub/bar.h => abc.h} |   10 +++++-----
 Tests/QtAutomoc/{foo.h => abc_p.h}   |   12 +++++++-----
 Tests/QtAutomoc/main.cpp             |    8 ++++++++
 Tests/QtAutomoc/{bar.cpp => xyz.cpp} |   12 ++++++------
 Tests/QtAutomoc/{sub/bar.h => xyz.h} |   10 +++++-----
 7 files changed, 51 insertions(+), 31 deletions(-)
 copy Tests/QtAutomoc/{foo.cpp => abc.cpp} (59%)
 copy Tests/QtAutomoc/{sub/bar.h => abc.h} (88%)
 copy Tests/QtAutomoc/{foo.h => abc_p.h} (81%)
 copy Tests/QtAutomoc/{bar.cpp => xyz.cpp} (86%)
 copy Tests/QtAutomoc/{sub/bar.h => xyz.h} (88%)


hooks/post-receive
-- 
CMake


More information about the Cmake-commits mailing list