To make this work both for GNOME Applications inside and outside the
authorMartin Baulig <martin@src.gnome.org>
Thu, 4 Feb 1999 13:27:05 +0000 (13:27 +0000)
committerMartin Baulig <martin@src.gnome.org>
Thu, 4 Feb 1999 13:27:05 +0000 (13:27 +0000)
GNOME CVS Tree I did the following:

* There is an `INSIDE_GNOME_COMMON' automake conditional which is defined
  in two places:

  - macros/aclocal-includes.m4 defines this to always be false.

  - gnome-common/configure.in does not include anything from macros and
    defines this to be true.

* We use this automake conditional in the macros/Makefile.am to install
  $(MACROS), autogen.sh, gnome-common.m4 and a newly created gnome-macros.dep
  in `$(datadir)/aclocal/gnome'.

  Since aclocal doesn't look in subdirectories we can safely install them
  there even when compiling from CVS.

  Also, there is no need to make any change to any existing application
  in the GNOME CVS Tree - really fine ...

* When we're outside the GNOME CVS Tree we simply need to tell aclocal that
  it should also look in `$(datadir)/aclocal/gnome' and it will find all
  the macros.

  The is a `gnome-skel' module in CVS that can be used as a starting point
  when writing a new GNOME Application that should be used outside CVS.

February  4, 1999,
Martin Baulig <martin@home-of-linux.org>

svn path=/trunk/; revision=609

Makefile.am
README
configure.in
gnome-common.spec [new file with mode: 0644]

index 484f4cf..e38ab08 100644 (file)
@@ -1,11 +1,9 @@
-## if <internationalization support>
-#SUBDIRS = po intl macros support # <your subdirs here>
-## else
-SUBDIRS = macros support # <your subdirs here>
-## endif
+SUBDIRS = macros
 
-## to automatically rebuild aclocal.m4 if any of the macros in
-## `macros/' change
-@MAINT@include macros/macros.dep
-@MAINT@macros/macros.dep: macros/Makefile.am
-@MAINT@        cd macros && $(MAKE) macros.dep
+EXTRA_DIST = gnome-common.spec
+
+dist-hook:
+       for subdir in intl support ; do \
+         mkdir $(distdir)/$$subdir ; \
+         cp -pr $(srcdir)/$$subdir $(distdir) ; \
+       done
diff --git a/README b/README
index f49049e..611a0a0 100644 (file)
--- a/README
+++ b/README
@@ -1,2 +1,35 @@
 This directory contains sample files that should be in pretty much every
 GNOME application.
+
+-----------------------------------------------------------------------------
+
+To make this work both for GNOME Applications inside and outside the
+GNOME CVS Tree I did the following:
+
+* There is an `INSIDE_GNOME_COMMON' automake conditional which is defined
+  in two places:
+
+  - macros/aclocal-includes.m4 defines this to always be false.
+
+  - gnome-common/configure.in does not include anything from macros and
+    defines this to be true.
+
+* We use this automake conditional in the macros/Makefile.am to install
+  $(MACROS), autogen.sh, gnome-common.m4 and a newly created gnome-macros.dep
+  in `$(datadir)/aclocal/gnome'.
+
+  Since aclocal doesn't look in subdirectories we can safely install them
+  there even when compiling from CVS.
+
+  Also, there is no need to make any change to any existing application
+  in the GNOME CVS Tree - really fine ...
+
+* When we're outside the GNOME CVS Tree we simply need to tell aclocal that
+  it should also look in `$(datadir)/aclocal/gnome' and it will find all
+  the macros.
+
+  The is a `gnome-skel' module in CVS that can be used as a starting point
+  when writing a new GNOME Application that should be used outside CVS.
+
+February  4, 1999,
+Martin Baulig <martin@home-of-linux.org>
index b618884..db2d990 100644 (file)
@@ -1,13 +1,11 @@
 AC_INIT(intl)
 
 AM_CONFIG_HEADER(config.h)
-AM_INIT_AUTOMAKE(gnome-common, 0.13)
+AM_INIT_AUTOMAKE(gnome-common, 0.99.5)
 
 AM_MAINTAINER_MODE
 
-AM_ACLOCAL_INCLUDE(macros)
-
-GNOME_INIT
+AM_CONDITIONAL(INSIDE_GNOME_COMMON, true)
 
 AC_ISC_POSIX
 AC_PROG_CC
@@ -16,21 +14,6 @@ AC_STDC_HEADERS
 AC_ARG_PROGRAM
 AM_PROG_LIBTOOL
 
-GNOME_SUPPORT_CHECKS
-
-dnl ## internationalization support
-dnl ALL_LINGUAS=""
-dnl AM_GNU_GETTEXT
-dnl AC_LINK_FILES($nls_cv_header_libgt, $nls_cv_header_intl)
-
-AC_OUTPUT(
+AC_OUTPUT([
 Makefile
-dnl ## internationalization support
-dnl po/Makefile.in
-dnl intl/Makefile
-macros/Makefile
-support/Makefile
-stamp.h)
-
-dnl ## internationalization support
-dnl stamp.h],[sed -e "/POTFILES =/r po/POTFILES" po/Makefile.in > po/Makefile])
+macros/Makefile])
diff --git a/gnome-common.spec b/gnome-common.spec
new file mode 100644 (file)
index 0000000..b4bd5ae
--- /dev/null
@@ -0,0 +1,64 @@
+# Note that this is NOT a relocatable package
+%define ver      0.99.5
+%define rel      SNAP
+%define prefix   /usr
+
+Summary: Gnome Common
+Name: gnome-common
+Version: %ver
+Release: %rel
+Copyright: LGPL
+Group: X11/Libraries
+Source: ftp://ftp.gnome.org/pub/GNOME/sources/gnome-common/gnome-common-%{ver}.tar.gz
+BuildRoot: /tmp/gnome-common-root
+URL: http://www.gnome.org
+Docdir: %{prefix}/doc
+
+%description
+This is required for every GNOME Application that is not in the
+GNOME CVS Tree.
+
+%package devel
+Summary: Required files for GNOME Applications outside CVS
+Group: X11/libraries
+
+%description devel
+This is required for every GNOME Application that is not in the
+GNOME CVS Tree.
+
+%prep
+%setup
+
+%build
+# Needed for snapshot releases.
+if [ ! -f configure ]; then
+  CFLAGS="$RPM_OPT_FLAGS" ./autogen.sh --prefix=%prefix
+else
+  CFLAGS="$RPM_OPT_FLAGS" ./configure --prefix=%prefix
+fi
+
+if [ "$SMP" != "" ]; then
+  (make "MAKE=make -k -j $SMP"; exit 0)
+  make
+else
+  make
+fi
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+make prefix=$RPM_BUILD_ROOT%{prefix} install
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%files
+%defattr(-, root, root)
+
+%doc AUTHORS COPYING ChangeLog NEWS README
+
+%files devel
+%defattr(-, root, root)
+
+%{prefix}/share/aclocal/gnome/*
+