Add documention builds for libgala and the full source of gala

This commit is contained in:
Rico Tzschichholz 2014-07-19 22:46:45 +02:00
parent 894d81f7a3
commit b93ab89061
5 changed files with 115 additions and 9 deletions

View File

@ -31,6 +31,8 @@ data/gschemas.compiled
data/org.pantheon.desktop.gala.gschema.valid
data/org.pantheon.desktop.gala.gschema.xml
data/org.pantheon.desktop.gala.gschema.xml.in
docs/gala
docs/libgala
lib/gala.vapi
po/*.gmo
po/.intltool-merge-cache

View File

@ -5,6 +5,7 @@ SUBDIRS = \
lib \
plugins \
src \
docs \
po \
vapi \
$(NULL)

View File

@ -127,8 +127,8 @@ GALA_CORE_VALA_PKGS="--pkg gio-unix-2.0 \
--pkg xfixes-4.0 \
--pkg plank"
VALAFLAGS="$VALAFLAGS --thread --target-glib=2.32"
VALAFLAGS="--target-glib=2.32"
VALAFLAGS_CORE="--thread"
PKG_CHECK_MODULES(GALA_CORE, $GALA_CORE_PKGS)
@ -159,7 +159,7 @@ fi
# 3.14
PKG_CHECK_MODULES(MUTTER314, [libmutter >= 3.13], [have_mutter314=yes], [have_mutter314=no])
if test "x$have_mutter314" = "xyes" ; then
PKG_CHECK_MODULES(MUTTER314, [libmutter >= 3.13.2])
PKG_CHECK_MODULES(MUTTER314, [libmutter >= 3.13.3])
VALAFLAGS="$VALAFLAGS --define HAS_MUTTER314"
MUTTER_API="3.14"
fi
@ -173,11 +173,37 @@ AC_ARG_ENABLE([debug],
AS_HELP_STRING([--disable-debug],[compile without debug code]),
[enable_debug=$enableval], [m4_if(gala_released, [1], [enable_debug=no], [enable_debug=yes])])
if test "x$enable_debug" = "xyes" ; then
VALAFLAGS="$VALAFLAGS -g"
VALAFLAGS_CORE="$VALAFLAGS_CORE -g"
fi
GALA_CORE_VALAFLAGS="$VALAFLAGS $GALA_CORE_VALA_PKGS"
GALA_CORE_VALAFLAGS="$VALAFLAGS $VALAFLAGS_CORE $GALA_CORE_VALA_PKGS"
AC_SUBST(GALA_CORE_VALAFLAGS)
GALA_DOCS_VALAFLAGS="$VALAFLAGS $GALA_CORE_VALA_PKGS"
AC_SUBST(GALA_DOCS_VALAFLAGS)
# -----------------------------------------------------------
# Documentation
# -----------------------------------------------------------
VALADOC_MIN_VERSION=0.3.1
AC_ARG_ENABLE([docs],
AS_HELP_STRING([--enable-docs],[Enable documentation generation]),
[enable_docs=$enableval], [enable_docs=no])
AM_CONDITIONAL([ENABLE_DOCS], [test "x$enable_docs" = "xyes"])
have_valadoc=no
if test "x$enable_docs" = "xyes"; then
# make sure the library is new enough and the program exists
PKG_CHECK_MODULES([VALADOC], [valadoc-1.0 >= $VALADOC_MIN_VERSION])
AC_PATH_PROG([VALADOC], [valadoc], [:])
AS_IF([test "$VALADOC" != :], have_valadoc=yes)
fi
AM_CONDITIONAL([HAVE_VALADOC], [test "x$have_valadoc" = "xyes"])
if test "x$enable_docs" = "xyes" -a "x$have_valadoc" != "xyes"; then
AC_MSG_ERROR([Doc building requested but valadoc not installed.])
fi
# -----------------------------------------------------------
# Gettext
@ -195,6 +221,7 @@ AC_CONFIG_FILES([
Makefile
src/Makefile
lib/Makefile
docs/Makefile
data/Makefile
vapi/Makefile
plugins/Makefile
@ -213,4 +240,6 @@ ${PACKAGE} ${VERSION}
C Compiler Flags............: ${CFLAGS}
Using Mutter................: ${MUTTER_API}
Documentation...............: ${have_valadoc}
"

76
docs/Makefile.am Normal file
View File

@ -0,0 +1,76 @@
include $(top_srcdir)/Makefile.common
libgala_doc_files = \
$(top_srcdir)/lib/Plugin.vala \
$(top_srcdir)/lib/Utils.vala \
$(top_srcdir)/lib/WindowManager.vala \
$(NULL)
gala_doc_files = \
$(top_srcdir)/src/DBus.vala \
$(top_srcdir)/src/DragDropAction.vala \
$(top_srcdir)/src/EndSessionDialog.vala \
$(top_srcdir)/src/InternalUtils.vala \
$(top_srcdir)/src/Main.vala \
$(top_srcdir)/src/PluginManager.vala \
$(top_srcdir)/src/ScreenSaver.vala \
$(top_srcdir)/src/Settings.vala \
$(top_srcdir)/src/ShadowEffect.vala \
$(top_srcdir)/src/TextShadowEffect.vala \
$(top_srcdir)/src/WindowListener.vala \
$(top_srcdir)/src/WindowManager.vala \
$(top_srcdir)/src/WorkspaceManager.vala \
$(top_srcdir)/src/Background/Background.vala \
$(top_srcdir)/src/Background/BackgroundCache.vala \
$(top_srcdir)/src/Background/BackgroundManager.vala \
$(top_srcdir)/src/Background/SlideShow.vala \
$(top_srcdir)/src/Background/SystemBackground.vala \
$(top_srcdir)/src/Widgets/IconGroup.vala \
$(top_srcdir)/src/Widgets/IconGroupContainer.vala \
$(top_srcdir)/src/Widgets/MonitorClone.vala \
$(top_srcdir)/src/Widgets/MultitaskingView.vala \
$(top_srcdir)/src/Widgets/WindowClone.vala \
$(top_srcdir)/src/Widgets/WindowCloneContainer.vala \
$(top_srcdir)/src/Widgets/WindowOverview.vala \
$(top_srcdir)/src/Widgets/WindowSwitcher.vala \
$(top_srcdir)/src/Widgets/WorkspaceClone.vala \
$(NULL)
valadoc_flags_gala = \
--force \
--verbose \
--package-name $(PACKAGE_NAME) \
--package-version $(PACKAGE_VERSION) \
$(GALA_DOCS_VALAFLAGS) \
--driver "`$(VALAC) --version`" \
--pkg config \
--pkg cogl-fixes \
--vapidir=$(top_builddir)/lib \
--vapidir=$(top_srcdir)/vapi \
$(NULL)
#if HAVE_VALADOC
all: html libhtml
html: $(libgala_doc_files) $(gala_doc_files) Makefile
$(AM_V_GEN)$(VALADOC) \
-o gala/ \
--doclet=html \
--internal \
$(valadoc_flags_gala) \
$(filter %.vala,$^)
libhtml: $(libgala_doc_files) Makefile
$(AM_V_GEN)$(VALADOC) \
-o libgala/ \
--doclet=html \
$(valadoc_flags_gala) \
$(filter %.vala,$^)
#endif
distclean-local: distclean-docs
distclean-docs:
rm -rf gala libgala

View File

@ -177,10 +177,8 @@ namespace Gala
workspace_manager.cleanup ();
}
/**
* Code ported from KWin present windows effect
* https://projects.kde.org/projects/kde/kde-workspace/repository/revisions/master/entry/kwin/effects/presentwindows/presentwindows.cpp
**/
// Code ported from KWin present windows effect
// https://projects.kde.org/projects/kde/kde-workspace/repository/revisions/master/entry/kwin/effects/presentwindows/presentwindows.cpp
// constants, mainly for natural expo
const int GAPS = 10;