[seahorse] Cleanup and reorganize build a bit



commit e320b56c413d95fbb1dde30f141108c20623f006
Author: Stef Walter <stefw gnome org>
Date:   Sun Apr 21 20:46:28 2013 +0200

    Cleanup and reorganize build a bit
    
    In particular put together a better facility for not printing
    certain warnings when building vala generated C code.

 .gitignore                        |   26 +++++++++++++-------------
 Makefile.am                       |    5 +++--
 build/Makefile.am                 |    4 ++++
 {m4 => build/m4}/introspection.m4 |    4 ++--
 common/Makefile.am                |   15 ++++++++++-----
 configure.ac                      |    9 +++++++--
 data/Makefile.am                  |    4 ++++
 m4/.gitignore                     |    7 -------
 8 files changed, 43 insertions(+), 31 deletions(-)
---
diff --git a/.gitignore b/.gitignore
index 99fb77c..3a37468 100644
--- a/.gitignore
+++ b/.gitignore
@@ -11,32 +11,26 @@
 ~*
 tmp-*
 *~
+*.stamp-t
 *.valid
+
 Makefile
 Makefile.in
 .deps
 .libs
 
-/configure.lineno
+/*.tar.gz
+
 /aclocal.m4
+/configure.lineno
 /autom4te.cache
-/config.*
+/config.log
+/config.status
 /configure
-/depcomp
-/stamp*
-/seahorse.p*
-
-/compile
-/*.tar.gz
 /seahorse-?.?.?
 /junk
-/install-sh
 /intltool-*
 /libtool
-/ltmain.sh
-/missing
-/mkinstalldirs
-/gtk-doc.make
 
 # Eclipse project files
 /.*project
@@ -51,5 +45,11 @@ Makefile.in
 /help/*/index.docbook
 /help/*/legal.xml
 
+/build/config.h*
+/build/m4/*
+/build/aux/*
+/build/stamp-h1
+
 /common/*.c
 /common/*.h
+/common/common.vapi
diff --git a/Makefile.am b/Makefile.am
index 9f89330..52c2426 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,6 +1,6 @@
 ## Process this file with automake to produce Makefile.in
 
-ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
+ACLOCAL_AMFLAGS = -I build/m4 ${ACLOCAL_FLAGS}
 
 if WITH_PKCS11
 PKCS11_DIR = pkcs11
@@ -20,7 +20,8 @@ else
 PGP_DIR = 
 endif
 
-SUBDIRS = libegg \
+SUBDIRS = build \
+       libegg \
        common \
        libseahorse \
        gkr \
diff --git a/build/Makefile.am b/build/Makefile.am
new file mode 100644
index 0000000..98c8d99
--- /dev/null
+++ b/build/Makefile.am
@@ -0,0 +1,4 @@
+include $(top_srcdir)/Makefile.decl
+
+EXTRA_DIST = \
+       $(NULL)
diff --git a/m4/introspection.m4 b/build/m4/introspection.m4
similarity index 99%
rename from m4/introspection.m4
rename to build/m4/introspection.m4
index 6e2c565..9ed23dc 100644
--- a/m4/introspection.m4
+++ b/build/m4/introspection.m4
@@ -21,7 +21,7 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
     ],[dnl
         AC_ARG_ENABLE(introspection,
                   AS_HELP_STRING([--enable-introspection[=@<:@no/auto/yes@:>@]],
-                                 [Enable introspection for this build]),, 
+                                 [Enable introspection for this build]),,
                                  [enable_introspection=auto])
     ])dnl
 
@@ -42,7 +42,7 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL],
     [auto],[dnl
         PKG_CHECK_EXISTS([gobject-introspection-1.0 >= $1], found_introspection=yes, found_introspection=no)
     ],dnl
-    [dnl       
+    [dnl
         AC_MSG_ERROR([invalid argument passed to --enable-introspection, should be one of 
@<:@no/auto/yes@:>@])
     ])dnl
 
diff --git a/common/Makefile.am b/common/Makefile.am
index e3eabf8..3929328 100644
--- a/common/Makefile.am
+++ b/common/Makefile.am
@@ -19,13 +19,18 @@ AM_VALAFLAGS = \
        --use-header \
        --header=seahorse-common.h \
        --pkg gtk+-3.0 \
+       --vapi=common.vapi \
        $(NULL)
 
-CFLAGS = \
-       -include config.h \
-       -Wno-unused-but-set-variable \
-       -Wno-pointer-sign \
+CFLAGS += \
+       -include config.h -w \
        $(NULL)
 
 EXTRA_DIST = \
-       seahorse-common.h
\ No newline at end of file
+       seahorse-common.h \
+       common.vapi \
+       $(NULL)
+
+DISTCLEANFILES = \
+       common.vapi \
+       $(NULL)
diff --git a/configure.ac b/configure.ac
index 66854b1..7b82a6c 100644
--- a/configure.ac
+++ b/configure.ac
@@ -14,15 +14,17 @@ AVAHI_GLIB_REQUIRED=0.6
 # -----------------------------------------------------------------------------
 # Basic tools
 
+AC_CONFIG_AUX_DIR([build/aux])
 AM_INIT_AUTOMAKE([1.11 tar-ustar foreign -Wno-portability])
 AM_SANITY_CHECK
-AC_CONFIG_HEADERS([config.h])
+AC_CONFIG_HEADERS([build/config.h])
 m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
 AM_MAINTAINER_MODE([enable])
-AC_CONFIG_MACRO_DIR([m4])
+AC_CONFIG_MACRO_DIR([build/m4])
 
 AC_PROG_CC
 AC_PROG_CXX
+AM_PROG_CC_C_O
 AM_PROG_VALAC([0.18.0])
 AC_PROG_INTLTOOL([0.35.0])
 AM_PROG_LIBTOOL
@@ -437,6 +439,8 @@ AM_CONDITIONAL(WITH_SSH, test "$enable_ssh" = "yes")
 # Compilation and linking options
 #
 
+CFLAGS="$CFLAGS -I\$(top_srcdir)/build"
+
 AC_MSG_CHECKING([for debug mode])
 AC_ARG_ENABLE(debug,
               AC_HELP_STRING([--enable-debug=no/default/yes],
@@ -546,6 +550,7 @@ AC_SUBST(VALA_FLAGS)
 
 AC_OUTPUT([
 Makefile
+build/Makefile
 common/Makefile
 gkr/Makefile
 libegg/Makefile
diff --git a/data/Makefile.am b/data/Makefile.am
index feb23fa..3ead1ba 100644
--- a/data/Makefile.am
+++ b/data/Makefile.am
@@ -28,3 +28,7 @@ EXTRA_DIST = \
        $(convert_DATA) \
        $(gsettings_SCHEMAS) \
        $(service_in_files)
+
+CLEANFILES = \
+       org.gnome.seahorse.Application.service \
+       $(NULL)


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]