Patrick Williams | b48b7b4 | 2016-08-17 15:04:38 -0500 | [diff] [blame^] | 1 | Upstream-Status: Backport [http://git.gnome.org/browse/unique/commit/?h=unique-1.1&id=f75ca2d7aad7d27686acca6090c1c569a79d7e63] |
| 2 | Signed-off-By: Ross Burton <ross.burton@intel.com> |
| 3 | |
| 4 | From f75ca2d7aad7d27686acca6090c1c569a79d7e63 Mon Sep 17 00:00:00 2001 |
| 5 | From: Emmanuele Bassi <ebassi@gnome.org> |
| 6 | Date: Sat, 08 May 2010 11:17:21 +0000 |
| 7 | Subject: build: Update the build environment |
| 8 | |
| 9 | Require autoconf 2.63, automake 1.11 and libtool 2.2.6 to remove Shave. |
| 10 | |
| 11 | Also bump up the requirement for gobject-introspection to 0.6.7. |
| 12 | --- |
| 13 | diff --git a/build/autotools/Makefile.am b/build/autotools/Makefile.am |
| 14 | index 5f35b85..b78428f 100644 |
| 15 | --- a/build/autotools/Makefile.am |
| 16 | +++ b/build/autotools/Makefile.am |
| 17 | @@ -1,7 +1,4 @@ |
| 18 | EXTRA_DIST = \ |
| 19 | - shave-libtool.in \ |
| 20 | - shave.in \ |
| 21 | - shave.m4 \ |
| 22 | as-compiler-flag.m4 \ |
| 23 | introspection.m4 \ |
| 24 | Makefile.am.enums \ |
| 25 | diff --git a/build/autotools/Makefile.am.silent b/build/autotools/Makefile.am.silent |
| 26 | index 249f6af..8576846 100644 |
| 27 | --- a/build/autotools/Makefile.am.silent |
| 28 | +++ b/build/autotools/Makefile.am.silent |
| 29 | @@ -1,10 +1,5 @@ |
| 30 | # custom rules for quiet builds |
| 31 | |
| 32 | -if USE_SHAVE |
| 33 | -QUIET_GEN = $(Q:@=@echo ' GEN '$@;) |
| 34 | -QUIET_LN = $(Q:@=@echo ' LN '$@;) |
| 35 | -QUIET_RM = $(Q:@=@echo ' RM '$@;) |
| 36 | -else |
| 37 | QUIET_GEN = $(AM_V_GEN) |
| 38 | |
| 39 | QUIET_LN = $(QUIET_LN_$(V)) |
| 40 | @@ -14,4 +9,3 @@ QUIET_LN_0 = @echo ' LN '$@; |
| 41 | QUIET_RM = $(QUIET_RM_$(V)) |
| 42 | QUIET_RM_ = $(QUIET_RM_$(AM_DEFAULT_VERBOSITY)) |
| 43 | QUIET_RM_0 = @echo ' RM '$@; |
| 44 | -endif # USE_SHAVE |
| 45 | diff --git a/build/autotools/introspection.m4 b/build/autotools/introspection.m4 |
| 46 | index f9ce49c..589721c 100644 |
| 47 | --- a/build/autotools/introspection.m4 |
| 48 | +++ b/build/autotools/introspection.m4 |
| 49 | @@ -59,12 +59,18 @@ m4_define([_GOBJECT_INTROSPECTION_CHECK_INTERNAL], |
| 50 | INTROSPECTION_GENERATE=`$PKG_CONFIG --variable=g_ir_generate gobject-introspection-1.0` |
| 51 | INTROSPECTION_GIRDIR=`$PKG_CONFIG --variable=girdir gobject-introspection-1.0` |
| 52 | INTROSPECTION_TYPELIBDIR="$($PKG_CONFIG --variable=typelibdir gobject-introspection-1.0)" |
| 53 | + INTROSPECTION_CFLAGS=`$PKG_CONFIG --cflags gobject-introspection-1.0` |
| 54 | + INTROSPECTION_LIBS=`$PKG_CONFIG --libs gobject-introspection-1.0` |
| 55 | + INTROSPECTION_MAKEFILE=`$PKG_CONFIG --variable=datadir gobject-introspection-1.0`/gobject-introspection-1.0/Makefile.introspection |
| 56 | fi |
| 57 | AC_SUBST(INTROSPECTION_SCANNER) |
| 58 | AC_SUBST(INTROSPECTION_COMPILER) |
| 59 | AC_SUBST(INTROSPECTION_GENERATE) |
| 60 | AC_SUBST(INTROSPECTION_GIRDIR) |
| 61 | AC_SUBST(INTROSPECTION_TYPELIBDIR) |
| 62 | + AC_SUBST(INTROSPECTION_CFLAGS) |
| 63 | + AC_SUBST(INTROSPECTION_LIBS) |
| 64 | + AC_SUBST(INTROSPECTION_MAKEFILE) |
| 65 | |
| 66 | AM_CONDITIONAL(HAVE_INTROSPECTION, test "x$found_introspection" = "xyes") |
| 67 | ]) |
| 68 | diff --git a/build/autotools/shave-libtool.in b/build/autotools/shave-libtool.in |
| 69 | deleted file mode 100644 |
| 70 | index 1f3a720..0000000 |
| 71 | --- a/build/autotools/shave-libtool.in |
| 72 | +++ b/dev/null |
| 73 | @@ -1,69 +0,0 @@ |
| 74 | -#!/bin/sh |
| 75 | - |
| 76 | -# we need sed |
| 77 | -SED=@SED@ |
| 78 | -if test -z "$SED" ; then |
| 79 | -SED=sed |
| 80 | -fi |
| 81 | - |
| 82 | -lt_unmangle () |
| 83 | -{ |
| 84 | - last_result=`echo $1 | $SED -e 's#.libs/##' -e 's#[0-9a-zA-Z_\-\.]*_la-##'` |
| 85 | -} |
| 86 | - |
| 87 | -# the real libtool to use |
| 88 | -LIBTOOL="$1" |
| 89 | -shift |
| 90 | - |
| 91 | -# if 1, don't print anything, the underlaying wrapper will do it |
| 92 | -pass_though=0 |
| 93 | - |
| 94 | -# scan the arguments, keep the right ones for libtool, and discover the mode |
| 95 | -preserved_args= |
| 96 | -while test "$#" -gt 0; do |
| 97 | - opt="$1" |
| 98 | - shift |
| 99 | - |
| 100 | - case $opt in |
| 101 | - --mode=*) |
| 102 | - mode=`echo $opt | $SED -e 's/[-_a-zA-Z0-9]*=//'` |
| 103 | - preserved_args="$preserved_args $opt" |
| 104 | - ;; |
| 105 | - -o) |
| 106 | - lt_output="$1" |
| 107 | - preserved_args="$preserved_args $opt" |
| 108 | - ;; |
| 109 | - *) |
| 110 | - preserved_args="$preserved_args $opt" |
| 111 | - ;; |
| 112 | - esac |
| 113 | -done |
| 114 | - |
| 115 | -case "$mode" in |
| 116 | -compile) |
| 117 | - # shave will be called and print the actual CC/CXX/LINK line |
| 118 | - preserved_args="$preserved_args --shave-mode=$mode" |
| 119 | - pass_though=1 |
| 120 | - ;; |
| 121 | -link) |
| 122 | - preserved_args="$preserved_args --shave-mode=$mode" |
| 123 | - Q=" LINK " |
| 124 | - ;; |
| 125 | -*) |
| 126 | - # let's u |
| 127 | - # echo "*** libtool: Unimplemented mode: $mode, fill a bug report" |
| 128 | - ;; |
| 129 | -esac |
| 130 | - |
| 131 | -lt_unmangle "$lt_output" |
| 132 | -output=$last_result |
| 133 | - |
| 134 | -if test -z $V; then |
| 135 | - if test $pass_though -eq 0; then |
| 136 | - echo "$Q$output" |
| 137 | - fi |
| 138 | - $LIBTOOL --silent $preserved_args |
| 139 | -else |
| 140 | - echo $LIBTOOL $preserved_args |
| 141 | - $LIBTOOL $preserved_args |
| 142 | -fi |
| 143 | diff --git a/build/autotools/shave.in b/build/autotools/shave.in |
| 144 | deleted file mode 100644 |
| 145 | index 5c16f27..0000000 |
| 146 | --- a/build/autotools/shave.in |
| 147 | +++ b/dev/null |
| 148 | @@ -1,79 +0,0 @@ |
| 149 | -#!/bin/sh |
| 150 | - |
| 151 | -# we need sed |
| 152 | -SED=@SED@ |
| 153 | -if test -z "$SED" ; then |
| 154 | -SED=sed |
| 155 | -fi |
| 156 | - |
| 157 | -lt_unmangle () |
| 158 | -{ |
| 159 | - last_result=`echo $1 | $SED -e 's#.libs/##' -e 's#[0-9a-zA-Z_\-\.]*_la-##'` |
| 160 | -} |
| 161 | - |
| 162 | -# the tool to wrap (cc, cxx, ar, ranlib, ..) |
| 163 | -tool="$1" |
| 164 | -shift |
| 165 | - |
| 166 | -# the reel tool (to call) |
| 167 | -REEL_TOOL="$1" |
| 168 | -shift |
| 169 | - |
| 170 | -pass_through=0 |
| 171 | -preserved_args= |
| 172 | -while test "$#" -gt 0; do |
| 173 | - opt="$1" |
| 174 | - shift |
| 175 | - |
| 176 | - case $opt in |
| 177 | - --shave-mode=*) |
| 178 | - mode=`echo $opt | $SED -e 's/[-_a-zA-Z0-9]*=//'` |
| 179 | - ;; |
| 180 | - -o) |
| 181 | - lt_output="$1" |
| 182 | - preserved_args="$preserved_args $opt" |
| 183 | - ;; |
| 184 | - *) |
| 185 | - preserved_args="$preserved_args $opt" |
| 186 | - ;; |
| 187 | - esac |
| 188 | -done |
| 189 | - |
| 190 | -# mode=link is handled in the libtool wrapper |
| 191 | -case "$mode,$tool" in |
| 192 | -link,*) |
| 193 | - pass_through=1 |
| 194 | - ;; |
| 195 | -*,cxx) |
| 196 | - Q=" CXX " |
| 197 | - ;; |
| 198 | -*,cc) |
| 199 | - Q=" CC " |
| 200 | - ;; |
| 201 | -*,fc) |
| 202 | - Q=" FC " |
| 203 | - ;; |
| 204 | -*,f77) |
| 205 | - Q=" F77 " |
| 206 | - ;; |
| 207 | -*,objc) |
| 208 | - Q=" OBJC " |
| 209 | - ;; |
| 210 | -*,*) |
| 211 | - # should not happen |
| 212 | - Q=" CC " |
| 213 | - ;; |
| 214 | -esac |
| 215 | - |
| 216 | -lt_unmangle "$lt_output" |
| 217 | -output=$last_result |
| 218 | - |
| 219 | -if test -z $V; then |
| 220 | - if test $pass_through -eq 0; then |
| 221 | - echo "$Q$output" |
| 222 | - fi |
| 223 | - $REEL_TOOL $preserved_args |
| 224 | -else |
| 225 | - echo $REEL_TOOL $preserved_args |
| 226 | - $REEL_TOOL $preserved_args |
| 227 | -fi |
| 228 | diff --git a/build/autotools/shave.m4 b/build/autotools/shave.m4 |
| 229 | deleted file mode 100644 |
| 230 | index 0a3509e..0000000 |
| 231 | --- a/build/autotools/shave.m4 |
| 232 | +++ b/dev/null |
| 233 | @@ -1,77 +0,0 @@ |
| 234 | -dnl Make automake/libtool output more friendly to humans |
| 235 | -dnl Damien Lespiau <damien.lespiau@gmail.com> |
| 236 | -dnl |
| 237 | -dnl SHAVE_INIT([shavedir],[default_mode]) |
| 238 | -dnl |
| 239 | -dnl shavedir: the directory where the shave scripts are, it defaults to |
| 240 | -dnl $(top_builddir) |
| 241 | -dnl default_mode: (enable|disable) default shave mode. This parameter |
| 242 | -dnl controls shave's behaviour when no option has been |
| 243 | -dnl given to configure. It defaults to disable. |
| 244 | -dnl |
| 245 | -dnl * SHAVE_INIT should be called late in your configure.(ac|in) file (just |
| 246 | -dnl before AC_CONFIG_FILE/AC_OUTPUT is perfect. This macro rewrites CC and |
| 247 | -dnl LIBTOOL, you don't want the configure tests to have these variables |
| 248 | -dnl re-defined. |
| 249 | -dnl * This macro requires GNU make's -s option. |
| 250 | - |
| 251 | -AC_DEFUN([_SHAVE_ARG_ENABLE], |
| 252 | -[ |
| 253 | - AC_ARG_ENABLE([shave], |
| 254 | - AS_HELP_STRING( |
| 255 | - [--enable-shave], |
| 256 | - [use shave to make the build pretty [[default=$1]]]),, |
| 257 | - [enable_shave=$1] |
| 258 | - ) |
| 259 | -]) |
| 260 | - |
| 261 | -AC_DEFUN([SHAVE_INIT], |
| 262 | -[ |
| 263 | - dnl you can tweak the default value of enable_shave |
| 264 | - m4_if([$2], [enable], [_SHAVE_ARG_ENABLE(yes)], [_SHAVE_ARG_ENABLE(no)]) |
| 265 | - |
| 266 | - if test x"$enable_shave" = xyes; then |
| 267 | - dnl where can we find the shave scripts? |
| 268 | - m4_if([$1],, |
| 269 | - [shavedir="$ac_pwd"], |
| 270 | - [shavedir="$ac_pwd/$1"]) |
| 271 | - AC_SUBST(shavedir) |
| 272 | - |
| 273 | - dnl make is now quiet |
| 274 | - AC_SUBST([MAKEFLAGS], [-s]) |
| 275 | - AC_SUBST([AM_MAKEFLAGS], ['`test -z $V && echo -s`']) |
| 276 | - |
| 277 | - dnl we need sed |
| 278 | - AC_CHECK_PROG(SED,sed,sed,false) |
| 279 | - |
| 280 | - dnl substitute libtool |
| 281 | - SHAVE_SAVED_LIBTOOL=$LIBTOOL |
| 282 | - LIBTOOL="${SHELL} ${shavedir}/shave-libtool '${SHAVE_SAVED_LIBTOOL}'" |
| 283 | - AC_SUBST(LIBTOOL) |
| 284 | - |
| 285 | - dnl substitute cc/cxx |
| 286 | - SHAVE_SAVED_CC=$CC |
| 287 | - SHAVE_SAVED_CXX=$CXX |
| 288 | - SHAVE_SAVED_FC=$FC |
| 289 | - SHAVE_SAVED_F77=$F77 |
| 290 | - SHAVE_SAVED_OBJC=$OBJC |
| 291 | - CC="${SHELL} ${shavedir}/shave cc ${SHAVE_SAVED_CC}" |
| 292 | - CXX="${SHELL} ${shavedir}/shave cxx ${SHAVE_SAVED_CXX}" |
| 293 | - FC="${SHELL} ${shavedir}/shave fc ${SHAVE_SAVED_FC}" |
| 294 | - F77="${SHELL} ${shavedir}/shave f77 ${SHAVE_SAVED_F77}" |
| 295 | - OBJC="${SHELL} ${shavedir}/shave objc ${SHAVE_SAVED_OBJC}" |
| 296 | - AC_SUBST(CC) |
| 297 | - AC_SUBST(CXX) |
| 298 | - AC_SUBST(FC) |
| 299 | - AC_SUBST(F77) |
| 300 | - AC_SUBST(OBJC) |
| 301 | - |
| 302 | - V=@ |
| 303 | - else |
| 304 | - V=1 |
| 305 | - fi |
| 306 | - Q='$(V:1=)' |
| 307 | - AC_SUBST(V) |
| 308 | - AC_SUBST(Q) |
| 309 | -]) |
| 310 | - |
| 311 | diff --git a/configure.ac b/configure.ac |
| 312 | index a3ed3ee..bc3163a 100644 |
| 313 | --- a/configure.ac |
| 314 | +++ b/configure.ac |
| 315 | @@ -14,7 +14,7 @@ m4_define([unique_api_version], [1.0]) |
| 316 | # This is the X.Y used in the protocol negotiation |
| 317 | m4_define([unique_protocol_version], [1.0]) |
| 318 | |
| 319 | -AC_PREREQ([2.59]) |
| 320 | +AC_PREREQ([2.63]) |
| 321 | |
| 322 | AC_INIT([unique], [unique_version], |
| 323 | [http://bugzilla.gnome.org/enter_bug.cgi?product=libunique], |
| 324 | @@ -23,9 +23,21 @@ AC_INIT([unique], [unique_version], |
| 325 | AC_CONFIG_SRCDIR([unique/unique.h]) |
| 326 | AC_CONFIG_MACRO_DIR([build/autotools]) |
| 327 | |
| 328 | -AM_INIT_AUTOMAKE([1.10]) |
| 329 | +AM_INIT_AUTOMAKE([1.11 no-define -Wno-portability dist-bzip2]) |
| 330 | AM_CONFIG_HEADER([config.h]) |
| 331 | |
| 332 | +AM_SILENT_RULES([yes]) |
| 333 | + |
| 334 | +AC_PROG_CC_C_O |
| 335 | + |
| 336 | +AM_PATH_GLIB_2_0 |
| 337 | + |
| 338 | +LT_PREREQ([2.2.6]) |
| 339 | +LT_INIT([disable-static]) |
| 340 | + |
| 341 | +# Honor aclocal flags |
| 342 | +ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS" |
| 343 | + |
| 344 | # version symbols |
| 345 | UNIQUE_MAJOR_VERSION=unique_major_version |
| 346 | UNIQUE_MINOR_VERSION=unique_minor_version |
| 347 | @@ -49,21 +61,6 @@ UNIQUE_LT_CURRENT_MINUS_AGE=m4_eval(lt_current - lt_age) |
| 348 | AC_SUBST(UNIQUE_LT_VERSION_INFO) |
| 349 | AC_SUBST(UNIQUE_LT_CURRENT_MINUS_AGE) |
| 350 | |
| 351 | -AC_ISC_POSIX |
| 352 | -AC_PROG_CC |
| 353 | -AC_PROG_INSTALL |
| 354 | -AC_PROG_MAKE_SET |
| 355 | -AC_C_CONST |
| 356 | -AC_PROG_LIBTOOL |
| 357 | -AC_PATH_PROG(GLIB_MKENUMS, [glib-mkenums]) |
| 358 | -AC_PATH_PROG(GLIB_GENMARSHAL, [glib-genmarshal]) |
| 359 | - |
| 360 | -AM_SANITY_CHECK |
| 361 | -AM_PROG_CC_STDC |
| 362 | - |
| 363 | -# Honor aclocal flags |
| 364 | -ACLOCAL="$ACLOCAL $ACLOCAL_FLAGS" |
| 365 | - |
| 366 | m4_define([glib_required], [2.12.0]) |
| 367 | m4_define([gtk_required], [2.11.0]) |
| 368 | m4_define([dbus_required], [0.70]) |
| 369 | @@ -122,7 +119,6 @@ AM_CONDITIONAL([HAVE_DBUS], [test "x$have_dbus" = "xyes"]) |
| 370 | dnl Bacon backend |
| 371 | dnl This is the fallback backend, so we *need* these headers and functions |
| 372 | dnl even if we end up using D-Bus |
| 373 | -dnl D-Bus backend dependencies |
| 374 | m4_define([have_bacon_default], [yes]) |
| 375 | AC_ARG_ENABLE([bacon], |
| 376 | [AC_HELP_STRING([--enable-bacon=@<:@yes/no@:>@], |
| 377 | @@ -178,9 +174,9 @@ AC_ARG_ENABLE([maintainer-flags], |
| 378 | AS_IF([test "x$enable_maintainer_flags" = "xyes" && test "x$GCC" = "xyes"], |
| 379 | [ |
| 380 | AS_COMPILER_FLAGS([MAINTAINER_CFLAGS], |
| 381 | - ["-Werror -Wall -Wshadow -Wcast-align |
| 382 | - -Wno-uninitialized -Wempty-body -Wformat-security |
| 383 | - -Winit-self"]) |
| 384 | + ["-Wall -Wshadow -Wcast-align |
| 385 | + -Wno-uninitialized -Wempty-body |
| 386 | + -Wformat-security -Winit-self"]) |
| 387 | ] |
| 388 | ) |
| 389 | |
| 390 | @@ -230,27 +226,10 @@ AC_DEFINE_UNQUOTED([GETTEXT_PACKAGE], |
| 391 | AM_GLIB_DEFINE_LOCALEDIR(UNIQUE_LOCALEDIR) |
| 392 | |
| 393 | # introspection |
| 394 | -GOBJECT_INTROSPECTION_CHECK([0.6.3]) |
| 395 | +GOBJECT_INTROSPECTION_CHECK([0.6.7]) |
| 396 | |
| 397 | # gtk-doc |
| 398 | -GTK_DOC_CHECK([1.11]) |
| 399 | - |
| 400 | -# nice builds |
| 401 | -m4_ifdef([AM_SILENT_RULES], |
| 402 | - [ |
| 403 | - AM_SILENT_RULES([yes]) |
| 404 | - use_shave=no |
| 405 | - ], |
| 406 | - [ |
| 407 | - SHAVE_INIT([build/autotools], [enable]) |
| 408 | - AC_CONFIG_FILES([ |
| 409 | - build/autotools/shave-libtool |
| 410 | - build/autotools/shave |
| 411 | - ]) |
| 412 | - use_shave=yes |
| 413 | - ]) |
| 414 | - |
| 415 | -AM_CONDITIONAL([USE_SHAVE], [test "x$use_shave" = "xyes"]) |
| 416 | +GTK_DOC_CHECK([1.13]) |
| 417 | |
| 418 | AC_CONFIG_FILES([ |
| 419 | Makefile |
| 420 | -- |
| 421 | cgit v0.9.0.2 |