Update to xsetroot 1.1.2
This commit is contained in:
parent
3488e8d2b1
commit
84bc3460e2
@ -1,3 +1,111 @@
|
|||||||
|
commit 04dbb108170ada979cce80e92053236c4b702e94
|
||||||
|
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Date: Fri Mar 9 20:20:44 2018 -0800
|
||||||
|
|
||||||
|
xsetroot 1.1.2
|
||||||
|
|
||||||
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
|
||||||
|
commit 8c926a2a2d3f1ed06e24259657e27800f2e0ff8c
|
||||||
|
Author: Mihail Konev <k.mvc@ya.ru>
|
||||||
|
Date: Thu Jan 26 14:00:21 2017 +1000
|
||||||
|
|
||||||
|
autogen: add default patch prefix
|
||||||
|
|
||||||
|
Signed-off-by: Mihail Konev <k.mvc@ya.ru>
|
||||||
|
|
||||||
|
commit c91cec09e0da17ccb7d1a7d2a120f9969e516622
|
||||||
|
Author: Emil Velikov <emil.l.velikov@gmail.com>
|
||||||
|
Date: Mon Mar 9 12:00:52 2015 +0000
|
||||||
|
|
||||||
|
autogen.sh: use quoted string variables
|
||||||
|
|
||||||
|
Place quotes around the $srcdir, $ORIGDIR and $0 variables to prevent
|
||||||
|
fall-outs, when they contain space.
|
||||||
|
|
||||||
|
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
|
||||||
|
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
|
||||||
|
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
||||||
|
|
||||||
|
commit beb935ffaa34fcc7e72ee53d471473533647e9fb
|
||||||
|
Author: Peter Hutterer <peter.hutterer@who-t.net>
|
||||||
|
Date: Tue Jan 24 10:32:07 2017 +1000
|
||||||
|
|
||||||
|
autogen.sh: use exec instead of waiting for configure to finish
|
||||||
|
|
||||||
|
Syncs the invocation of configure with the one from the server.
|
||||||
|
|
||||||
|
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
|
||||||
|
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
|
||||||
|
|
||||||
|
commit ff223d5595c292f0ccee9f4690f11b29157ef3ab
|
||||||
|
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Date: Wed Dec 31 11:35:47 2014 -0800
|
||||||
|
|
||||||
|
Only use results from GetWindowProperty if it returned success
|
||||||
|
|
||||||
|
Since Xlib prior to 1.6 didn't always clear values on failure, don't
|
||||||
|
assume they're safe to use unless we succeeded.
|
||||||
|
|
||||||
|
Reported by Oracle Parfait 1.5.1:
|
||||||
|
Error: Uninitialised memory (CWE 456)
|
||||||
|
Possible access to uninitialised memory '&after'
|
||||||
|
at line 328 of xsetroot.c in function 'FixupState'.
|
||||||
|
&after allocated at line 317.
|
||||||
|
Possible access to uninitialised memory '&data'
|
||||||
|
at line 330 of xsetroot.c in function 'FixupState'.
|
||||||
|
&data allocated at line 318.
|
||||||
|
Possible access to uninitialised memory '&format'
|
||||||
|
at line 328 of xsetroot.c in function 'FixupState'.
|
||||||
|
&format allocated at line 316.
|
||||||
|
Possible access to uninitialised memory '&length'
|
||||||
|
at line 328 of xsetroot.c in function 'FixupState'.
|
||||||
|
&length allocated at line 317.
|
||||||
|
Possible access to uninitialised memory '&type'
|
||||||
|
at line 328 of xsetroot.c in function 'FixupState'.
|
||||||
|
&type allocated at line 315.
|
||||||
|
at line 331 of xsetroot.c in function 'FixupState'.
|
||||||
|
&type allocated at line 315.
|
||||||
|
|
||||||
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
|
||||||
|
|
||||||
|
commit cd298a5f8e345791c1889bdd781fddc01c94fc1d
|
||||||
|
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Date: Tue Jun 3 23:22:14 2014 -0700
|
||||||
|
|
||||||
|
Print which option was in error along with usage message
|
||||||
|
|
||||||
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
|
||||||
|
commit e7d7181b7e7eafc3019f4eb806a0aeb8e38806fa
|
||||||
|
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Date: Tue Jun 3 23:04:08 2014 -0700
|
||||||
|
|
||||||
|
autogen.sh: Honor NOCONFIGURE=1
|
||||||
|
|
||||||
|
See http://people.gnome.org/~walters/docs/build-api.txt
|
||||||
|
|
||||||
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
|
||||||
|
commit ed899cfe8675cca8875156ce35b9d2b4553f9cca
|
||||||
|
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Date: Tue Jun 3 23:04:08 2014 -0700
|
||||||
|
|
||||||
|
configure: Drop AM_MAINTAINER_MODE
|
||||||
|
|
||||||
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
|
||||||
|
commit 6ce1479493af8ade3ce7e41276e0e64c878461e2
|
||||||
|
Author: Stéphane Aulery <lkppo@free.fr>
|
||||||
|
Date: Sun Jul 7 23:23:52 2013 +0200
|
||||||
|
|
||||||
|
Improve manpage and -help option.
|
||||||
|
|
||||||
|
Signed-off-by: Stéphane Aulery <lkppo@free.fr>
|
||||||
|
Reviewed-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
|
|
||||||
commit a33c612c5ff84ba2d6004d99e96ec6919bb8e859
|
commit a33c612c5ff84ba2d6004d99e96ec6919bb8e859
|
||||||
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
Author: Alan Coopersmith <alan.coopersmith@oracle.com>
|
||||||
Date: Tue Jan 22 23:02:52 2013 -0800
|
Date: Tue Jan 22 23:02:52 2013 -0800
|
||||||
|
@ -75,8 +75,8 @@ bin_PROGRAMS = xsetroot$(EXEEXT)
|
|||||||
subdir = .
|
subdir = .
|
||||||
DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
|
DIST_COMMON = README $(am__configure_deps) $(srcdir)/Makefile.am \
|
||||||
$(srcdir)/Makefile.in $(srcdir)/config.h.in \
|
$(srcdir)/Makefile.in $(srcdir)/config.h.in \
|
||||||
$(top_srcdir)/configure COPYING ChangeLog INSTALL config.guess \
|
$(top_srcdir)/configure COPYING ChangeLog INSTALL compile \
|
||||||
config.sub depcomp install-sh missing
|
config.guess config.sub depcomp install-sh missing
|
||||||
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
|
||||||
am__aclocal_m4_deps = $(top_srcdir)/configure.ac
|
am__aclocal_m4_deps = $(top_srcdir)/configure.ac
|
||||||
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
|
||||||
|
64
app/xsetroot/aclocal.m4
vendored
64
app/xsetroot/aclocal.m4
vendored
@ -1242,7 +1242,7 @@ AC_SUBST([am__untar])
|
|||||||
|
|
||||||
dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure.
|
dnl xorg-macros.m4. Generated from xorg-macros.m4.in xorgversion.m4 by configure.
|
||||||
dnl
|
dnl
|
||||||
dnl Copyright (c) 2005, 2006, Oracle and/or its affiliates. All rights reserved.
|
dnl Copyright (c) 2005, 2015, Oracle and/or its affiliates. All rights reserved.
|
||||||
dnl
|
dnl
|
||||||
dnl Permission is hereby granted, free of charge, to any person obtaining a
|
dnl Permission is hereby granted, free of charge, to any person obtaining a
|
||||||
dnl copy of this software and associated documentation files (the "Software"),
|
dnl copy of this software and associated documentation files (the "Software"),
|
||||||
@ -1279,7 +1279,7 @@ dnl DEALINGS IN THE SOFTWARE.
|
|||||||
# See the "minimum version" comment for each macro you use to see what
|
# See the "minimum version" comment for each macro you use to see what
|
||||||
# version you require.
|
# version you require.
|
||||||
m4_defun([XORG_MACROS_VERSION],[
|
m4_defun([XORG_MACROS_VERSION],[
|
||||||
m4_define([vers_have], [1.19.0])
|
m4_define([vers_have], [1.19.2])
|
||||||
m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.])))
|
m4_define([maj_have], m4_substr(vers_have, 0, m4_index(vers_have, [.])))
|
||||||
m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.])))
|
m4_define([maj_needed], m4_substr([$1], 0, m4_index([$1], [.])))
|
||||||
m4_if(m4_cmp(maj_have, maj_needed), 0,,
|
m4_if(m4_cmp(maj_have, maj_needed), 0,,
|
||||||
@ -1357,6 +1357,17 @@ AC_DEFUN([XORG_MANPAGE_SECTIONS],[
|
|||||||
AC_REQUIRE([AC_CANONICAL_HOST])
|
AC_REQUIRE([AC_CANONICAL_HOST])
|
||||||
AC_REQUIRE([AC_PROG_SED])
|
AC_REQUIRE([AC_PROG_SED])
|
||||||
|
|
||||||
|
case $host_os in
|
||||||
|
solaris*)
|
||||||
|
# Solaris 2.0 - 11.3 use SysV man page section numbers, so we
|
||||||
|
# check for a man page file found in later versions that use
|
||||||
|
# traditional section numbers instead
|
||||||
|
AC_CHECK_FILE([/usr/share/man/man7/attributes.7],
|
||||||
|
[SYSV_MAN_SECTIONS=false], [SYSV_MAN_SECTIONS=true])
|
||||||
|
;;
|
||||||
|
*) SYSV_MAN_SECTIONS=false ;;
|
||||||
|
esac
|
||||||
|
|
||||||
if test x$APP_MAN_SUFFIX = x ; then
|
if test x$APP_MAN_SUFFIX = x ; then
|
||||||
APP_MAN_SUFFIX=1
|
APP_MAN_SUFFIX=1
|
||||||
fi
|
fi
|
||||||
@ -1372,9 +1383,9 @@ if test x$LIB_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$FILE_MAN_SUFFIX = x ; then
|
if test x$FILE_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) FILE_MAN_SUFFIX=4 ;;
|
true) FILE_MAN_SUFFIX=4 ;;
|
||||||
*) FILE_MAN_SUFFIX=5 ;;
|
*) FILE_MAN_SUFFIX=5 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$FILE_MAN_DIR = x ; then
|
if test x$FILE_MAN_DIR = x ; then
|
||||||
@ -1382,9 +1393,9 @@ if test x$FILE_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$MISC_MAN_SUFFIX = x ; then
|
if test x$MISC_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) MISC_MAN_SUFFIX=5 ;;
|
true) MISC_MAN_SUFFIX=5 ;;
|
||||||
*) MISC_MAN_SUFFIX=7 ;;
|
*) MISC_MAN_SUFFIX=7 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$MISC_MAN_DIR = x ; then
|
if test x$MISC_MAN_DIR = x ; then
|
||||||
@ -1392,9 +1403,9 @@ if test x$MISC_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$DRIVER_MAN_SUFFIX = x ; then
|
if test x$DRIVER_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) DRIVER_MAN_SUFFIX=7 ;;
|
true) DRIVER_MAN_SUFFIX=7 ;;
|
||||||
*) DRIVER_MAN_SUFFIX=4 ;;
|
*) DRIVER_MAN_SUFFIX=4 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$DRIVER_MAN_DIR = x ; then
|
if test x$DRIVER_MAN_DIR = x ; then
|
||||||
@ -1402,9 +1413,9 @@ if test x$DRIVER_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$ADMIN_MAN_SUFFIX = x ; then
|
if test x$ADMIN_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) ADMIN_MAN_SUFFIX=1m ;;
|
true) ADMIN_MAN_SUFFIX=1m ;;
|
||||||
*) ADMIN_MAN_SUFFIX=8 ;;
|
*) ADMIN_MAN_SUFFIX=8 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$ADMIN_MAN_DIR = x ; then
|
if test x$ADMIN_MAN_DIR = x ; then
|
||||||
@ -1665,13 +1676,24 @@ m4_ifval([$1],
|
|||||||
fi])
|
fi])
|
||||||
|
|
||||||
# Test for the ability of xmlto to generate a text target
|
# Test for the ability of xmlto to generate a text target
|
||||||
|
#
|
||||||
|
# NOTE: xmlto 0.0.27 or higher return a non-zero return code in the
|
||||||
|
# following test for empty XML docbook files.
|
||||||
|
# For compatibility reasons use the following empty XML docbook file and if
|
||||||
|
# it fails try it again with a non-empty XML file.
|
||||||
have_xmlto_text=no
|
have_xmlto_text=no
|
||||||
cat > conftest.xml << "EOF"
|
cat > conftest.xml << "EOF"
|
||||||
EOF
|
EOF
|
||||||
AS_IF([test "$have_xmlto" = yes],
|
AS_IF([test "$have_xmlto" = yes],
|
||||||
[AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1],
|
[AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1],
|
||||||
[have_xmlto_text=yes],
|
[have_xmlto_text=yes],
|
||||||
[AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])])
|
[# Try it again with a non-empty XML file.
|
||||||
|
cat > conftest.xml << "EOF"
|
||||||
|
<x></x>
|
||||||
|
EOF
|
||||||
|
AS_IF([$XMLTO --skip-validation txt conftest.xml >/dev/null 2>&1],
|
||||||
|
[have_xmlto_text=yes],
|
||||||
|
[AC_MSG_WARN([xmlto cannot generate text format, this format skipped])])])])
|
||||||
rm -f conftest.xml
|
rm -f conftest.xml
|
||||||
AM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes])
|
AM_CONDITIONAL([HAVE_XMLTO_TEXT], [test $have_xmlto_text = yes])
|
||||||
AM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes])
|
AM_CONDITIONAL([HAVE_XMLTO], [test "$have_xmlto" = yes])
|
||||||
@ -3067,8 +3089,9 @@ AC_REQUIRE([PKG_PROG_PKG_CONFIG])
|
|||||||
macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros`
|
macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros`
|
||||||
INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \
|
INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \
|
||||||
mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \
|
mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \
|
||||||
|| (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \
|
|| (rm -f \$(top_srcdir)/.INSTALL.tmp; test -e \$(top_srcdir)/INSTALL || ( \
|
||||||
echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)"
|
touch \$(top_srcdir)/INSTALL; \
|
||||||
|
echo 'failed to copy INSTALL from util-macros: installing empty INSTALL.' >&2))"
|
||||||
AC_SUBST([INSTALL_CMD])
|
AC_SUBST([INSTALL_CMD])
|
||||||
]) # XORG_INSTALL
|
]) # XORG_INSTALL
|
||||||
dnl Copyright 2005 Red Hat, Inc
|
dnl Copyright 2005 Red Hat, Inc
|
||||||
@ -3129,10 +3152,11 @@ AC_DEFUN([XORG_RELEASE_VERSION],[
|
|||||||
#
|
#
|
||||||
#
|
#
|
||||||
AC_DEFUN([XORG_CHANGELOG], [
|
AC_DEFUN([XORG_CHANGELOG], [
|
||||||
CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \
|
CHANGELOG_CMD="((GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp) 2>/dev/null && \
|
||||||
mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \
|
mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \
|
||||||
|| (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \
|
|| (rm -f \$(top_srcdir)/.changelog.tmp; test -e \$(top_srcdir)/ChangeLog || ( \
|
||||||
echo 'git directory not found: installing possibly empty changelog.' >&2)"
|
touch \$(top_srcdir)/ChangeLog; \
|
||||||
|
echo 'git failed to create ChangeLog: installing empty ChangeLog.' >&2))"
|
||||||
AC_SUBST([CHANGELOG_CMD])
|
AC_SUBST([CHANGELOG_CMD])
|
||||||
]) # XORG_CHANGELOG
|
]) # XORG_CHANGELOG
|
||||||
|
|
||||||
|
347
app/xsetroot/compile
Normal file
347
app/xsetroot/compile
Normal file
@ -0,0 +1,347 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
# Wrapper for compilers which do not understand '-c -o'.
|
||||||
|
|
||||||
|
scriptversion=2012-10-14.11; # UTC
|
||||||
|
|
||||||
|
# Copyright (C) 1999-2014 Free Software Foundation, Inc.
|
||||||
|
# Written by Tom Tromey <tromey@cygnus.com>.
|
||||||
|
#
|
||||||
|
# This program is free software; you can redistribute it and/or modify
|
||||||
|
# it under the terms of the GNU General Public License as published by
|
||||||
|
# the Free Software Foundation; either version 2, or (at your option)
|
||||||
|
# any later version.
|
||||||
|
#
|
||||||
|
# This program is distributed in the hope that it will be useful,
|
||||||
|
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||||
|
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||||
|
# GNU General Public License for more details.
|
||||||
|
#
|
||||||
|
# You should have received a copy of the GNU General Public License
|
||||||
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
|
# As a special exception to the GNU General Public License, if you
|
||||||
|
# distribute this file as part of a program that contains a
|
||||||
|
# configuration script generated by Autoconf, you may include it under
|
||||||
|
# the same distribution terms that you use for the rest of that program.
|
||||||
|
|
||||||
|
# This file is maintained in Automake, please report
|
||||||
|
# bugs to <bug-automake@gnu.org> or send patches to
|
||||||
|
# <automake-patches@gnu.org>.
|
||||||
|
|
||||||
|
nl='
|
||||||
|
'
|
||||||
|
|
||||||
|
# We need space, tab and new line, in precisely that order. Quoting is
|
||||||
|
# there to prevent tools from complaining about whitespace usage.
|
||||||
|
IFS=" "" $nl"
|
||||||
|
|
||||||
|
file_conv=
|
||||||
|
|
||||||
|
# func_file_conv build_file lazy
|
||||||
|
# Convert a $build file to $host form and store it in $file
|
||||||
|
# Currently only supports Windows hosts. If the determined conversion
|
||||||
|
# type is listed in (the comma separated) LAZY, no conversion will
|
||||||
|
# take place.
|
||||||
|
func_file_conv ()
|
||||||
|
{
|
||||||
|
file=$1
|
||||||
|
case $file in
|
||||||
|
/ | /[!/]*) # absolute file, and not a UNC file
|
||||||
|
if test -z "$file_conv"; then
|
||||||
|
# lazily determine how to convert abs files
|
||||||
|
case `uname -s` in
|
||||||
|
MINGW*)
|
||||||
|
file_conv=mingw
|
||||||
|
;;
|
||||||
|
CYGWIN*)
|
||||||
|
file_conv=cygwin
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
file_conv=wine
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
case $file_conv/,$2, in
|
||||||
|
*,$file_conv,*)
|
||||||
|
;;
|
||||||
|
mingw/*)
|
||||||
|
file=`cmd //C echo "$file " | sed -e 's/"\(.*\) " *$/\1/'`
|
||||||
|
;;
|
||||||
|
cygwin/*)
|
||||||
|
file=`cygpath -m "$file" || echo "$file"`
|
||||||
|
;;
|
||||||
|
wine/*)
|
||||||
|
file=`winepath -w "$file" || echo "$file"`
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
# func_cl_dashL linkdir
|
||||||
|
# Make cl look for libraries in LINKDIR
|
||||||
|
func_cl_dashL ()
|
||||||
|
{
|
||||||
|
func_file_conv "$1"
|
||||||
|
if test -z "$lib_path"; then
|
||||||
|
lib_path=$file
|
||||||
|
else
|
||||||
|
lib_path="$lib_path;$file"
|
||||||
|
fi
|
||||||
|
linker_opts="$linker_opts -LIBPATH:$file"
|
||||||
|
}
|
||||||
|
|
||||||
|
# func_cl_dashl library
|
||||||
|
# Do a library search-path lookup for cl
|
||||||
|
func_cl_dashl ()
|
||||||
|
{
|
||||||
|
lib=$1
|
||||||
|
found=no
|
||||||
|
save_IFS=$IFS
|
||||||
|
IFS=';'
|
||||||
|
for dir in $lib_path $LIB
|
||||||
|
do
|
||||||
|
IFS=$save_IFS
|
||||||
|
if $shared && test -f "$dir/$lib.dll.lib"; then
|
||||||
|
found=yes
|
||||||
|
lib=$dir/$lib.dll.lib
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
if test -f "$dir/$lib.lib"; then
|
||||||
|
found=yes
|
||||||
|
lib=$dir/$lib.lib
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
if test -f "$dir/lib$lib.a"; then
|
||||||
|
found=yes
|
||||||
|
lib=$dir/lib$lib.a
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
IFS=$save_IFS
|
||||||
|
|
||||||
|
if test "$found" != yes; then
|
||||||
|
lib=$lib.lib
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# func_cl_wrapper cl arg...
|
||||||
|
# Adjust compile command to suit cl
|
||||||
|
func_cl_wrapper ()
|
||||||
|
{
|
||||||
|
# Assume a capable shell
|
||||||
|
lib_path=
|
||||||
|
shared=:
|
||||||
|
linker_opts=
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
if test -n "$eat"; then
|
||||||
|
eat=
|
||||||
|
else
|
||||||
|
case $1 in
|
||||||
|
-o)
|
||||||
|
# configure might choose to run compile as 'compile cc -o foo foo.c'.
|
||||||
|
eat=1
|
||||||
|
case $2 in
|
||||||
|
*.o | *.[oO][bB][jJ])
|
||||||
|
func_file_conv "$2"
|
||||||
|
set x "$@" -Fo"$file"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
func_file_conv "$2"
|
||||||
|
set x "$@" -Fe"$file"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
-I)
|
||||||
|
eat=1
|
||||||
|
func_file_conv "$2" mingw
|
||||||
|
set x "$@" -I"$file"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-I*)
|
||||||
|
func_file_conv "${1#-I}" mingw
|
||||||
|
set x "$@" -I"$file"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-l)
|
||||||
|
eat=1
|
||||||
|
func_cl_dashl "$2"
|
||||||
|
set x "$@" "$lib"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-l*)
|
||||||
|
func_cl_dashl "${1#-l}"
|
||||||
|
set x "$@" "$lib"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
-L)
|
||||||
|
eat=1
|
||||||
|
func_cl_dashL "$2"
|
||||||
|
;;
|
||||||
|
-L*)
|
||||||
|
func_cl_dashL "${1#-L}"
|
||||||
|
;;
|
||||||
|
-static)
|
||||||
|
shared=false
|
||||||
|
;;
|
||||||
|
-Wl,*)
|
||||||
|
arg=${1#-Wl,}
|
||||||
|
save_ifs="$IFS"; IFS=','
|
||||||
|
for flag in $arg; do
|
||||||
|
IFS="$save_ifs"
|
||||||
|
linker_opts="$linker_opts $flag"
|
||||||
|
done
|
||||||
|
IFS="$save_ifs"
|
||||||
|
;;
|
||||||
|
-Xlinker)
|
||||||
|
eat=1
|
||||||
|
linker_opts="$linker_opts $2"
|
||||||
|
;;
|
||||||
|
-*)
|
||||||
|
set x "$@" "$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*.cc | *.CC | *.cxx | *.CXX | *.[cC]++)
|
||||||
|
func_file_conv "$1"
|
||||||
|
set x "$@" -Tp"$file"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*.c | *.cpp | *.CPP | *.lib | *.LIB | *.Lib | *.OBJ | *.obj | *.[oO])
|
||||||
|
func_file_conv "$1" mingw
|
||||||
|
set x "$@" "$file"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set x "$@" "$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
if test -n "$linker_opts"; then
|
||||||
|
linker_opts="-link$linker_opts"
|
||||||
|
fi
|
||||||
|
exec "$@" $linker_opts
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
eat=
|
||||||
|
|
||||||
|
case $1 in
|
||||||
|
'')
|
||||||
|
echo "$0: No command. Try '$0 --help' for more information." 1>&2
|
||||||
|
exit 1;
|
||||||
|
;;
|
||||||
|
-h | --h*)
|
||||||
|
cat <<\EOF
|
||||||
|
Usage: compile [--help] [--version] PROGRAM [ARGS]
|
||||||
|
|
||||||
|
Wrapper for compilers which do not understand '-c -o'.
|
||||||
|
Remove '-o dest.o' from ARGS, run PROGRAM with the remaining
|
||||||
|
arguments, and rename the output as expected.
|
||||||
|
|
||||||
|
If you are trying to build a whole package this is not the
|
||||||
|
right script to run: please start by reading the file 'INSTALL'.
|
||||||
|
|
||||||
|
Report bugs to <bug-automake@gnu.org>.
|
||||||
|
EOF
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
-v | --v*)
|
||||||
|
echo "compile $scriptversion"
|
||||||
|
exit $?
|
||||||
|
;;
|
||||||
|
cl | *[/\\]cl | cl.exe | *[/\\]cl.exe )
|
||||||
|
func_cl_wrapper "$@" # Doesn't return...
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
ofile=
|
||||||
|
cfile=
|
||||||
|
|
||||||
|
for arg
|
||||||
|
do
|
||||||
|
if test -n "$eat"; then
|
||||||
|
eat=
|
||||||
|
else
|
||||||
|
case $1 in
|
||||||
|
-o)
|
||||||
|
# configure might choose to run compile as 'compile cc -o foo foo.c'.
|
||||||
|
# So we strip '-o arg' only if arg is an object.
|
||||||
|
eat=1
|
||||||
|
case $2 in
|
||||||
|
*.o | *.obj)
|
||||||
|
ofile=$2
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set x "$@" -o "$2"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
*.c)
|
||||||
|
cfile=$1
|
||||||
|
set x "$@" "$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
set x "$@" "$1"
|
||||||
|
shift
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
||||||
|
shift
|
||||||
|
done
|
||||||
|
|
||||||
|
if test -z "$ofile" || test -z "$cfile"; then
|
||||||
|
# If no '-o' option was seen then we might have been invoked from a
|
||||||
|
# pattern rule where we don't need one. That is ok -- this is a
|
||||||
|
# normal compilation that the losing compiler can handle. If no
|
||||||
|
# '.c' file was seen then we are probably linking. That is also
|
||||||
|
# ok.
|
||||||
|
exec "$@"
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Name of file we expect compiler to create.
|
||||||
|
cofile=`echo "$cfile" | sed 's|^.*[\\/]||; s|^[a-zA-Z]:||; s/\.c$/.o/'`
|
||||||
|
|
||||||
|
# Create the lock directory.
|
||||||
|
# Note: use '[/\\:.-]' here to ensure that we don't use the same name
|
||||||
|
# that we are using for the .o file. Also, base the name on the expected
|
||||||
|
# object file name, since that is what matters with a parallel build.
|
||||||
|
lockdir=`echo "$cofile" | sed -e 's|[/\\:.-]|_|g'`.d
|
||||||
|
while true; do
|
||||||
|
if mkdir "$lockdir" >/dev/null 2>&1; then
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
sleep 1
|
||||||
|
done
|
||||||
|
# FIXME: race condition here if user kills between mkdir and trap.
|
||||||
|
trap "rmdir '$lockdir'; exit 1" 1 2 15
|
||||||
|
|
||||||
|
# Run the compile.
|
||||||
|
"$@"
|
||||||
|
ret=$?
|
||||||
|
|
||||||
|
if test -f "$cofile"; then
|
||||||
|
test "$cofile" = "$ofile" || mv "$cofile" "$ofile"
|
||||||
|
elif test -f "${cofile}bj"; then
|
||||||
|
test "${cofile}bj" = "$ofile" || mv "${cofile}bj" "$ofile"
|
||||||
|
fi
|
||||||
|
|
||||||
|
rmdir "$lockdir"
|
||||||
|
exit $ret
|
||||||
|
|
||||||
|
# Local Variables:
|
||||||
|
# mode: shell-script
|
||||||
|
# sh-indentation: 2
|
||||||
|
# eval: (add-hook 'write-file-hooks 'time-stamp)
|
||||||
|
# time-stamp-start: "scriptversion="
|
||||||
|
# time-stamp-format: "%:y-%02m-%02d.%02H"
|
||||||
|
# time-stamp-time-zone: "UTC"
|
||||||
|
# time-stamp-end: "; # UTC"
|
||||||
|
# End:
|
104
app/xsetroot/configure
vendored
104
app/xsetroot/configure
vendored
@ -1,6 +1,6 @@
|
|||||||
#! /bin/sh
|
#! /bin/sh
|
||||||
# Guess values for system-dependent variables and create Makefiles.
|
# Guess values for system-dependent variables and create Makefiles.
|
||||||
# Generated by GNU Autoconf 2.69 for xsetroot 1.1.1.
|
# Generated by GNU Autoconf 2.69 for xsetroot 1.1.2.
|
||||||
#
|
#
|
||||||
# Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>.
|
# Report bugs to <https://bugs.freedesktop.org/enter_bug.cgi?product=xorg>.
|
||||||
#
|
#
|
||||||
@ -581,8 +581,8 @@ MAKEFLAGS=
|
|||||||
# Identity of this package.
|
# Identity of this package.
|
||||||
PACKAGE_NAME='xsetroot'
|
PACKAGE_NAME='xsetroot'
|
||||||
PACKAGE_TARNAME='xsetroot'
|
PACKAGE_TARNAME='xsetroot'
|
||||||
PACKAGE_VERSION='1.1.1'
|
PACKAGE_VERSION='1.1.2'
|
||||||
PACKAGE_STRING='xsetroot 1.1.1'
|
PACKAGE_STRING='xsetroot 1.1.2'
|
||||||
PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg'
|
PACKAGE_BUGREPORT='https://bugs.freedesktop.org/enter_bug.cgi?product=xorg'
|
||||||
PACKAGE_URL=''
|
PACKAGE_URL=''
|
||||||
|
|
||||||
@ -1318,7 +1318,7 @@ if test "$ac_init_help" = "long"; then
|
|||||||
# Omit some internal or obsolete options to make the list less imposing.
|
# Omit some internal or obsolete options to make the list less imposing.
|
||||||
# This message is too long to be a string in the A/UX 3.1 sh.
|
# This message is too long to be a string in the A/UX 3.1 sh.
|
||||||
cat <<_ACEOF
|
cat <<_ACEOF
|
||||||
\`configure' configures xsetroot 1.1.1 to adapt to many kinds of systems.
|
\`configure' configures xsetroot 1.1.2 to adapt to many kinds of systems.
|
||||||
|
|
||||||
Usage: $0 [OPTION]... [VAR=VALUE]...
|
Usage: $0 [OPTION]... [VAR=VALUE]...
|
||||||
|
|
||||||
@ -1388,7 +1388,7 @@ fi
|
|||||||
|
|
||||||
if test -n "$ac_init_help"; then
|
if test -n "$ac_init_help"; then
|
||||||
case $ac_init_help in
|
case $ac_init_help in
|
||||||
short | recursive ) echo "Configuration of xsetroot 1.1.1:";;
|
short | recursive ) echo "Configuration of xsetroot 1.1.2:";;
|
||||||
esac
|
esac
|
||||||
cat <<\_ACEOF
|
cat <<\_ACEOF
|
||||||
|
|
||||||
@ -1505,7 +1505,7 @@ fi
|
|||||||
test -n "$ac_init_help" && exit $ac_status
|
test -n "$ac_init_help" && exit $ac_status
|
||||||
if $ac_init_version; then
|
if $ac_init_version; then
|
||||||
cat <<\_ACEOF
|
cat <<\_ACEOF
|
||||||
xsetroot configure 1.1.1
|
xsetroot configure 1.1.2
|
||||||
generated by GNU Autoconf 2.69
|
generated by GNU Autoconf 2.69
|
||||||
|
|
||||||
Copyright (C) 2012 Free Software Foundation, Inc.
|
Copyright (C) 2012 Free Software Foundation, Inc.
|
||||||
@ -1762,7 +1762,7 @@ cat >config.log <<_ACEOF
|
|||||||
This file contains any messages produced by compilers while
|
This file contains any messages produced by compilers while
|
||||||
running configure, to aid debugging if configure makes a mistake.
|
running configure, to aid debugging if configure makes a mistake.
|
||||||
|
|
||||||
It was created by xsetroot $as_me 1.1.1, which was
|
It was created by xsetroot $as_me 1.1.2, which was
|
||||||
generated by GNU Autoconf 2.69. Invocation command line was
|
generated by GNU Autoconf 2.69. Invocation command line was
|
||||||
|
|
||||||
$ $0 $@
|
$ $0 $@
|
||||||
@ -2591,7 +2591,7 @@ fi
|
|||||||
|
|
||||||
# Define the identity of the package.
|
# Define the identity of the package.
|
||||||
PACKAGE='xsetroot'
|
PACKAGE='xsetroot'
|
||||||
VERSION='1.1.1'
|
VERSION='1.1.2'
|
||||||
|
|
||||||
|
|
||||||
cat >>confdefs.h <<_ACEOF
|
cat >>confdefs.h <<_ACEOF
|
||||||
@ -10258,10 +10258,11 @@ _ACEOF
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
CHANGELOG_CMD="(GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp && \
|
CHANGELOG_CMD="((GIT_DIR=\$(top_srcdir)/.git git log > \$(top_srcdir)/.changelog.tmp) 2>/dev/null && \
|
||||||
mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \
|
mv \$(top_srcdir)/.changelog.tmp \$(top_srcdir)/ChangeLog) \
|
||||||
|| (rm -f \$(top_srcdir)/.changelog.tmp; touch \$(top_srcdir)/ChangeLog; \
|
|| (rm -f \$(top_srcdir)/.changelog.tmp; test -e \$(top_srcdir)/ChangeLog || ( \
|
||||||
echo 'git directory not found: installing possibly empty changelog.' >&2)"
|
touch \$(top_srcdir)/ChangeLog; \
|
||||||
|
echo 'git failed to create ChangeLog: installing empty ChangeLog.' >&2))"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@ -10269,14 +10270,45 @@ echo 'git directory not found: installing possibly empty changelog.' >&2)"
|
|||||||
macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros`
|
macros_datadir=`$PKG_CONFIG --print-errors --variable=pkgdatadir xorg-macros`
|
||||||
INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \
|
INSTALL_CMD="(cp -f "$macros_datadir/INSTALL" \$(top_srcdir)/.INSTALL.tmp && \
|
||||||
mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \
|
mv \$(top_srcdir)/.INSTALL.tmp \$(top_srcdir)/INSTALL) \
|
||||||
|| (rm -f \$(top_srcdir)/.INSTALL.tmp; touch \$(top_srcdir)/INSTALL; \
|
|| (rm -f \$(top_srcdir)/.INSTALL.tmp; test -e \$(top_srcdir)/INSTALL || ( \
|
||||||
echo 'util-macros \"pkgdatadir\" from xorg-macros.pc not found: installing possibly empty INSTALL.' >&2)"
|
touch \$(top_srcdir)/INSTALL; \
|
||||||
|
echo 'failed to copy INSTALL from util-macros: installing empty INSTALL.' >&2))"
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
case $host_os in
|
||||||
|
solaris*)
|
||||||
|
# Solaris 2.0 - 11.3 use SysV man page section numbers, so we
|
||||||
|
# check for a man page file found in later versions that use
|
||||||
|
# traditional section numbers instead
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for /usr/share/man/man7/attributes.7" >&5
|
||||||
|
$as_echo_n "checking for /usr/share/man/man7/attributes.7... " >&6; }
|
||||||
|
if ${ac_cv_file__usr_share_man_man7_attributes_7+:} false; then :
|
||||||
|
$as_echo_n "(cached) " >&6
|
||||||
|
else
|
||||||
|
test "$cross_compiling" = yes &&
|
||||||
|
as_fn_error $? "cannot check for file existence when cross compiling" "$LINENO" 5
|
||||||
|
if test -r "/usr/share/man/man7/attributes.7"; then
|
||||||
|
ac_cv_file__usr_share_man_man7_attributes_7=yes
|
||||||
|
else
|
||||||
|
ac_cv_file__usr_share_man_man7_attributes_7=no
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_file__usr_share_man_man7_attributes_7" >&5
|
||||||
|
$as_echo "$ac_cv_file__usr_share_man_man7_attributes_7" >&6; }
|
||||||
|
if test "x$ac_cv_file__usr_share_man_man7_attributes_7" = xyes; then :
|
||||||
|
SYSV_MAN_SECTIONS=false
|
||||||
|
else
|
||||||
|
SYSV_MAN_SECTIONS=true
|
||||||
|
fi
|
||||||
|
|
||||||
|
;;
|
||||||
|
*) SYSV_MAN_SECTIONS=false ;;
|
||||||
|
esac
|
||||||
|
|
||||||
if test x$APP_MAN_SUFFIX = x ; then
|
if test x$APP_MAN_SUFFIX = x ; then
|
||||||
APP_MAN_SUFFIX=1
|
APP_MAN_SUFFIX=1
|
||||||
fi
|
fi
|
||||||
@ -10292,9 +10324,9 @@ if test x$LIB_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$FILE_MAN_SUFFIX = x ; then
|
if test x$FILE_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) FILE_MAN_SUFFIX=4 ;;
|
true) FILE_MAN_SUFFIX=4 ;;
|
||||||
*) FILE_MAN_SUFFIX=5 ;;
|
*) FILE_MAN_SUFFIX=5 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$FILE_MAN_DIR = x ; then
|
if test x$FILE_MAN_DIR = x ; then
|
||||||
@ -10302,9 +10334,9 @@ if test x$FILE_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$MISC_MAN_SUFFIX = x ; then
|
if test x$MISC_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) MISC_MAN_SUFFIX=5 ;;
|
true) MISC_MAN_SUFFIX=5 ;;
|
||||||
*) MISC_MAN_SUFFIX=7 ;;
|
*) MISC_MAN_SUFFIX=7 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$MISC_MAN_DIR = x ; then
|
if test x$MISC_MAN_DIR = x ; then
|
||||||
@ -10312,9 +10344,9 @@ if test x$MISC_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$DRIVER_MAN_SUFFIX = x ; then
|
if test x$DRIVER_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) DRIVER_MAN_SUFFIX=7 ;;
|
true) DRIVER_MAN_SUFFIX=7 ;;
|
||||||
*) DRIVER_MAN_SUFFIX=4 ;;
|
*) DRIVER_MAN_SUFFIX=4 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$DRIVER_MAN_DIR = x ; then
|
if test x$DRIVER_MAN_DIR = x ; then
|
||||||
@ -10322,9 +10354,9 @@ if test x$DRIVER_MAN_DIR = x ; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test x$ADMIN_MAN_SUFFIX = x ; then
|
if test x$ADMIN_MAN_SUFFIX = x ; then
|
||||||
case $host_os in
|
case $SYSV_MAN_SECTIONS in
|
||||||
solaris*) ADMIN_MAN_SUFFIX=1m ;;
|
true) ADMIN_MAN_SUFFIX=1m ;;
|
||||||
*) ADMIN_MAN_SUFFIX=8 ;;
|
*) ADMIN_MAN_SUFFIX=8 ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
if test x$ADMIN_MAN_DIR = x ; then
|
if test x$ADMIN_MAN_DIR = x ; then
|
||||||
@ -10414,12 +10446,12 @@ if test -n "$XSETROOT_CFLAGS"; then
|
|||||||
pkg_cv_XSETROOT_CFLAGS="$XSETROOT_CFLAGS"
|
pkg_cv_XSETROOT_CFLAGS="$XSETROOT_CFLAGS"
|
||||||
elif test -n "$PKG_CONFIG"; then
|
elif test -n "$PKG_CONFIG"; then
|
||||||
if test -n "$PKG_CONFIG" && \
|
if test -n "$PKG_CONFIG" && \
|
||||||
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xmuu x11 xbitmaps xcursor xproto >= 7.0.17\""; } >&5
|
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xmuu x11 xbitmaps xcursor xproto >= 7.0.25\""; } >&5
|
||||||
($PKG_CONFIG --exists --print-errors "xmuu x11 xbitmaps xcursor xproto >= 7.0.17") 2>&5
|
($PKG_CONFIG --exists --print-errors "xmuu x11 xbitmaps xcursor xproto >= 7.0.25") 2>&5
|
||||||
ac_status=$?
|
ac_status=$?
|
||||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||||
test $ac_status = 0; }; then
|
test $ac_status = 0; }; then
|
||||||
pkg_cv_XSETROOT_CFLAGS=`$PKG_CONFIG --cflags "xmuu x11 xbitmaps xcursor xproto >= 7.0.17" 2>/dev/null`
|
pkg_cv_XSETROOT_CFLAGS=`$PKG_CONFIG --cflags "xmuu x11 xbitmaps xcursor xproto >= 7.0.25" 2>/dev/null`
|
||||||
test "x$?" != "x0" && pkg_failed=yes
|
test "x$?" != "x0" && pkg_failed=yes
|
||||||
else
|
else
|
||||||
pkg_failed=yes
|
pkg_failed=yes
|
||||||
@ -10431,12 +10463,12 @@ if test -n "$XSETROOT_LIBS"; then
|
|||||||
pkg_cv_XSETROOT_LIBS="$XSETROOT_LIBS"
|
pkg_cv_XSETROOT_LIBS="$XSETROOT_LIBS"
|
||||||
elif test -n "$PKG_CONFIG"; then
|
elif test -n "$PKG_CONFIG"; then
|
||||||
if test -n "$PKG_CONFIG" && \
|
if test -n "$PKG_CONFIG" && \
|
||||||
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xmuu x11 xbitmaps xcursor xproto >= 7.0.17\""; } >&5
|
{ { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"xmuu x11 xbitmaps xcursor xproto >= 7.0.25\""; } >&5
|
||||||
($PKG_CONFIG --exists --print-errors "xmuu x11 xbitmaps xcursor xproto >= 7.0.17") 2>&5
|
($PKG_CONFIG --exists --print-errors "xmuu x11 xbitmaps xcursor xproto >= 7.0.25") 2>&5
|
||||||
ac_status=$?
|
ac_status=$?
|
||||||
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
$as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
|
||||||
test $ac_status = 0; }; then
|
test $ac_status = 0; }; then
|
||||||
pkg_cv_XSETROOT_LIBS=`$PKG_CONFIG --libs "xmuu x11 xbitmaps xcursor xproto >= 7.0.17" 2>/dev/null`
|
pkg_cv_XSETROOT_LIBS=`$PKG_CONFIG --libs "xmuu x11 xbitmaps xcursor xproto >= 7.0.25" 2>/dev/null`
|
||||||
test "x$?" != "x0" && pkg_failed=yes
|
test "x$?" != "x0" && pkg_failed=yes
|
||||||
else
|
else
|
||||||
pkg_failed=yes
|
pkg_failed=yes
|
||||||
@ -10457,14 +10489,14 @@ else
|
|||||||
_pkg_short_errors_supported=no
|
_pkg_short_errors_supported=no
|
||||||
fi
|
fi
|
||||||
if test $_pkg_short_errors_supported = yes; then
|
if test $_pkg_short_errors_supported = yes; then
|
||||||
XSETROOT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "xmuu x11 xbitmaps xcursor xproto >= 7.0.17" 2>&1`
|
XSETROOT_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors --cflags --libs "xmuu x11 xbitmaps xcursor xproto >= 7.0.25" 2>&1`
|
||||||
else
|
else
|
||||||
XSETROOT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "xmuu x11 xbitmaps xcursor xproto >= 7.0.17" 2>&1`
|
XSETROOT_PKG_ERRORS=`$PKG_CONFIG --print-errors --cflags --libs "xmuu x11 xbitmaps xcursor xproto >= 7.0.25" 2>&1`
|
||||||
fi
|
fi
|
||||||
# Put the nasty error message in config.log where it belongs
|
# Put the nasty error message in config.log where it belongs
|
||||||
echo "$XSETROOT_PKG_ERRORS" >&5
|
echo "$XSETROOT_PKG_ERRORS" >&5
|
||||||
|
|
||||||
as_fn_error $? "Package requirements (xmuu x11 xbitmaps xcursor xproto >= 7.0.17) were not met:
|
as_fn_error $? "Package requirements (xmuu x11 xbitmaps xcursor xproto >= 7.0.25) were not met:
|
||||||
|
|
||||||
$XSETROOT_PKG_ERRORS
|
$XSETROOT_PKG_ERRORS
|
||||||
|
|
||||||
@ -11143,7 +11175,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
|
|||||||
# report actual input values of CONFIG_FILES etc. instead of their
|
# report actual input values of CONFIG_FILES etc. instead of their
|
||||||
# values after options handling.
|
# values after options handling.
|
||||||
ac_log="
|
ac_log="
|
||||||
This file was extended by xsetroot $as_me 1.1.1, which was
|
This file was extended by xsetroot $as_me 1.1.2, which was
|
||||||
generated by GNU Autoconf 2.69. Invocation command line was
|
generated by GNU Autoconf 2.69. Invocation command line was
|
||||||
|
|
||||||
CONFIG_FILES = $CONFIG_FILES
|
CONFIG_FILES = $CONFIG_FILES
|
||||||
@ -11209,7 +11241,7 @@ _ACEOF
|
|||||||
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
|
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
|
||||||
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
|
ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`"
|
||||||
ac_cs_version="\\
|
ac_cs_version="\\
|
||||||
xsetroot config.status 1.1.1
|
xsetroot config.status 1.1.2
|
||||||
configured by $0, generated by GNU Autoconf 2.69,
|
configured by $0, generated by GNU Autoconf 2.69,
|
||||||
with options \\"\$ac_cs_config\\"
|
with options \\"\$ac_cs_config\\"
|
||||||
|
|
||||||
|
@ -23,7 +23,7 @@ dnl Process this file with autoconf to create configure.
|
|||||||
|
|
||||||
# Initialize Autoconf
|
# Initialize Autoconf
|
||||||
AC_PREREQ([2.60])
|
AC_PREREQ([2.60])
|
||||||
AC_INIT([xsetroot], [1.1.1],
|
AC_INIT([xsetroot], [1.1.2],
|
||||||
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [xsetroot])
|
[https://bugs.freedesktop.org/enter_bug.cgi?product=xorg], [xsetroot])
|
||||||
AC_CONFIG_SRCDIR([Makefile.am])
|
AC_CONFIG_SRCDIR([Makefile.am])
|
||||||
AC_CONFIG_HEADERS([config.h])
|
AC_CONFIG_HEADERS([config.h])
|
||||||
@ -39,7 +39,7 @@ XORG_MACROS_VERSION(1.8)
|
|||||||
XORG_DEFAULT_OPTIONS
|
XORG_DEFAULT_OPTIONS
|
||||||
|
|
||||||
# Checks for pkg-config packages
|
# Checks for pkg-config packages
|
||||||
PKG_CHECK_MODULES(XSETROOT, [xmuu x11 xbitmaps xcursor xproto >= 7.0.17])
|
PKG_CHECK_MODULES(XSETROOT, [xmuu x11 xbitmaps xcursor xproto >= 7.0.25])
|
||||||
|
|
||||||
XORG_WITH_LINT
|
XORG_WITH_LINT
|
||||||
|
|
||||||
|
@ -27,13 +27,23 @@
|
|||||||
xsetroot \- root window parameter setting utility for X
|
xsetroot \- root window parameter setting utility for X
|
||||||
.SH SYNOPSIS
|
.SH SYNOPSIS
|
||||||
.B xsetroot
|
.B xsetroot
|
||||||
[-help] [-version] [-def] [-display \fIdisplay\fP]
|
[-help]
|
||||||
|
[-version]
|
||||||
|
[-def]
|
||||||
|
[-display \fIdisplay\fP]
|
||||||
[-cursor \fIcursorfile maskfile\fP]
|
[-cursor \fIcursorfile maskfile\fP]
|
||||||
[-cursor_name \fIcursorname\fP]
|
[-cursor_name \fIcursorfontname\fP]
|
||||||
[-xcf \fIcursorfile\fP \fIcursorsize\fP]
|
[-xcf \fIcursorfile\fP \fIcursorsize\fP]
|
||||||
[-bitmap \fIfilename\fP]
|
[-bitmap \fIfilename\fP
|
||||||
[-mod \fIx y\fP] [-gray] [-grey] [-fg \fIcolor\fP] [-bg \fIcolor\fP] [-rv]
|
| -mod \fIx y\fP
|
||||||
[-solid \fIcolor\fP] [-name \fIstring\fP]
|
| -gray
|
||||||
|
| -grey
|
||||||
|
| -solid \fIcolor\fP]
|
||||||
|
[-bg \fIcolor\fP]
|
||||||
|
[-fg \fIcolor\fP]
|
||||||
|
[-rv]
|
||||||
|
[-name \fIstring\fP]
|
||||||
|
[-d \fIdisplay\fP]
|
||||||
.SH DESCRIPTION
|
.SH DESCRIPTION
|
||||||
The
|
The
|
||||||
.I xsetroot
|
.I xsetroot
|
||||||
@ -56,11 +66,11 @@ Only one of the background color/tiling changing options
|
|||||||
.SH OPTIONS
|
.SH OPTIONS
|
||||||
.PP
|
.PP
|
||||||
The various options are as follows:
|
The various options are as follows:
|
||||||
.IP \fB-help\fP
|
.IP "\fB-help\fP"
|
||||||
Print a usage message and exit.
|
Print a usage message and exit.
|
||||||
.IP \fB-verson\fP
|
.IP "\fB-version\fP"
|
||||||
Print a version message and exit.
|
Print a version message and exit.
|
||||||
.IP \fB-def\fP
|
.IP "\fB-def, -default\fP"
|
||||||
Reset unspecified attributes to the default values. (Restores the background
|
Reset unspecified attributes to the default values. (Restores the background
|
||||||
to the familiar gray mesh and the cursor to the hollow x shape.)
|
to the familiar gray mesh and the cursor to the hollow x shape.)
|
||||||
.IP "\fB-cursor\fP \fIcursorfile\fP \fImaskfile\fP"
|
.IP "\fB-cursor\fP \fIcursorfile\fP \fImaskfile\fP"
|
||||||
@ -70,7 +80,7 @@ Cursor and mask files are bitmaps (little pictures), and can be made with the
|
|||||||
.I bitmap(__appmansuffix__)
|
.I bitmap(__appmansuffix__)
|
||||||
program. You probably want the mask file to be all black until you
|
program. You probably want the mask file to be all black until you
|
||||||
get used to the way masks work.
|
get used to the way masks work.
|
||||||
.IP "\fB-cursor_name\fP \fIcursorname\fP
|
.IP "\fB-cursor_name\fP \fIcursorfontname\fP"
|
||||||
This lets you change the pointer cursor to one of the standard
|
This lets you change the pointer cursor to one of the standard
|
||||||
cursors from the cursor font. Refer to appendix B of the X protocol for
|
cursors from the cursor font. Refer to appendix B of the X protocol for
|
||||||
the names (except that the XC_ prefix is elided for this option).
|
the names (except that the XC_ prefix is elided for this option).
|
||||||
@ -87,16 +97,14 @@ the bitmap.
|
|||||||
This is used if you want a plaid-like grid pattern on your screen.
|
This is used if you want a plaid-like grid pattern on your screen.
|
||||||
x and y are integers ranging from 1 to 16. Try the different combinations.
|
x and y are integers ranging from 1 to 16. Try the different combinations.
|
||||||
Zero and negative numbers are taken as 1.
|
Zero and negative numbers are taken as 1.
|
||||||
.IP \fB-gray\fP
|
.IP "\fB-gray, -grey\fP"
|
||||||
Make the entire background gray. (Easier on the eyes.)
|
Make the entire background gray (Easier on the eyes).
|
||||||
.IP \fB-grey\fP
|
.IP "\fB-bg, -background\fP \fIcolor\fP"
|
||||||
Make the entire background grey.
|
Use ``color'' as the background color.
|
||||||
.IP "\fB-fg\fP \fIcolor\fP"
|
.IP "\fB-fg, -foreground\fP \fIcolor\fP"
|
||||||
Use ``color'' as the foreground color. Foreground and background colors
|
Use ``color'' as the foreground color. Foreground and background colors
|
||||||
are meaningful only in combination with -cursor, -bitmap, or -mod.
|
are meaningful only in combination with -cursor, -bitmap, or -mod.
|
||||||
.IP "\fB-bg\fP \fIcolor\fP"
|
.IP "\fB-rv, -reverse\fP"
|
||||||
Use ``color'' as the background color.
|
|
||||||
.IP \fB-rv\fP
|
|
||||||
This exchanges the foreground and background colors. Normally the foreground
|
This exchanges the foreground and background colors. Normally the foreground
|
||||||
color is black and the background color is white.
|
color is black and the background color is white.
|
||||||
.IP "\fB-solid\fP \fIcolor\fP"
|
.IP "\fB-solid\fP \fIcolor\fP"
|
||||||
@ -107,7 +115,7 @@ Set the name of the root window to ``string''. There is no default value.
|
|||||||
Usually a name is assigned to a window so that the
|
Usually a name is assigned to a window so that the
|
||||||
window manager can use a text representation when the window is iconified.
|
window manager can use a text representation when the window is iconified.
|
||||||
This option is unused since you can't iconify the background.
|
This option is unused since you can't iconify the background.
|
||||||
.IP "\fB-display\fP \fIdisplay\fP"
|
.IP "\fB-d, -display\fP \fIdisplay\fP"
|
||||||
Specifies the server to connect to; see \fIX(__miscmansuffix__)\fP.
|
Specifies the server to connect to; see \fIX(__miscmansuffix__)\fP.
|
||||||
.SH "SEE ALSO"
|
.SH "SEE ALSO"
|
||||||
X(__miscmansuffix__), xset(__appmansuffix__), xrdb(__appmansuffix__), Xcursor(__libmansuffix__)
|
X(__miscmansuffix__), xset(__appmansuffix__), xrdb(__appmansuffix__), Xcursor(__libmansuffix__)
|
||||||
|
@ -59,7 +59,6 @@ static int save_colors = 0;
|
|||||||
static int unsave_past = 0;
|
static int unsave_past = 0;
|
||||||
static Pixmap save_pixmap = (Pixmap)None;
|
static Pixmap save_pixmap = (Pixmap)None;
|
||||||
|
|
||||||
static void usage(void) _X_NORETURN;
|
|
||||||
static void FixupState(void);
|
static void FixupState(void);
|
||||||
static void SetBackgroundToBitmap(Pixmap bitmap,
|
static void SetBackgroundToBitmap(Pixmap bitmap,
|
||||||
unsigned int width, unsigned int height);
|
unsigned int width, unsigned int height);
|
||||||
@ -70,26 +69,29 @@ static XColor NameToXColor(char *name, unsigned long pixel);
|
|||||||
static unsigned long NameToPixel(char *name, unsigned long pixel);
|
static unsigned long NameToPixel(char *name, unsigned long pixel);
|
||||||
static Pixmap ReadBitmapFile(char *filename, unsigned int *width, unsigned int *height, int *x_hot, int *y_hot);
|
static Pixmap ReadBitmapFile(char *filename, unsigned int *width, unsigned int *height, int *x_hot, int *y_hot);
|
||||||
|
|
||||||
static void
|
static void _X_NORETURN _X_COLD
|
||||||
usage(void)
|
usage(const char *errmsg)
|
||||||
{
|
{
|
||||||
fprintf(stderr, "usage: %s [options]\n%s\n", program_name,
|
if (errmsg != NULL)
|
||||||
|
fprintf (stderr, "%s: %s\n\n", program_name, errmsg);
|
||||||
|
|
||||||
|
fprintf(stderr, "Usage: %s [options]\n%s\n", program_name,
|
||||||
" where options are:\n"
|
" where options are:\n"
|
||||||
" -display <display> or -d <display>\n"
|
" -help Print this help\n"
|
||||||
" -fg <color> or -foreground <color>\n"
|
" -version Print a version message\n"
|
||||||
" -bg <color> or -background <color>\n"
|
" -def, -default Reset unspecified attributes\n"
|
||||||
" -rv or -reverse\n"
|
" -cursor <cursorfile> <maskfile> Pointer cursor used when outside of any windows\n"
|
||||||
" -def or -default\n"
|
" -cursor_name <cursorfontname> Use a pointer cursor from the cursor font\n"
|
||||||
" -name <string>\n"
|
" -xcf <cursorfile> <cursorsize> Load a pointer cursor from an Xcursor file\n"
|
||||||
" -cursor <cursor file> <mask file>\n"
|
" -bitmap <filename> Use the bitmap specified in the file\n"
|
||||||
" -cursor_name <cursor-font name>\n"
|
" -mod <x> <y> Use a plaid-like grid pattern on screen\n"
|
||||||
" -xcf <ARGB cursor file> <cursor size>\n"
|
" -gray, -grey Make the entire background grey\n"
|
||||||
" -solid <color>\n"
|
" -bg, -background <color> Set background color\n"
|
||||||
" -gray or -grey\n"
|
" -fg, -foreground <color> Set foreground color\n"
|
||||||
" -bitmap <filename>\n"
|
" -rv, -reverse Swap foreground and background colors\n"
|
||||||
" -mod <x> <y>\n"
|
" -solid <color> Set the background of the root window\n"
|
||||||
" -help\n"
|
" -name <string> Set the name of the root window\n"
|
||||||
" -version\n"
|
" -d, -display <display> Specifies the server to connect to\n"
|
||||||
);
|
);
|
||||||
exit(1);
|
exit(1);
|
||||||
/*NOTREACHED*/
|
/*NOTREACHED*/
|
||||||
@ -123,12 +125,12 @@ main(int argc, char *argv[])
|
|||||||
|
|
||||||
for (i = 1; i < argc; i++) {
|
for (i = 1; i < argc; i++) {
|
||||||
if (!strcmp ("-display", argv[i]) || !strcmp ("-d", argv[i])) {
|
if (!strcmp ("-display", argv[i]) || !strcmp ("-d", argv[i])) {
|
||||||
if (++i>=argc) usage ();
|
if (++i>=argc) usage ("-display requires an argument");
|
||||||
display_name = argv[i];
|
display_name = argv[i];
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-help", argv[i])) {
|
if (!strcmp("-help", argv[i])) {
|
||||||
usage();
|
usage(NULL);
|
||||||
}
|
}
|
||||||
if (!strcmp("-version", argv[i])) {
|
if (!strcmp("-version", argv[i])) {
|
||||||
printf("%s\n", PACKAGE_STRING);
|
printf("%s\n", PACKAGE_STRING);
|
||||||
@ -139,29 +141,33 @@ main(int argc, char *argv[])
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-name", argv[i])) {
|
if (!strcmp("-name", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("-name requires an argument");
|
||||||
name = argv[i];
|
name = argv[i];
|
||||||
nonexcl++;
|
nonexcl++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-cursor", argv[i])) {
|
if (!strcmp("-cursor", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc)
|
||||||
|
usage("missing cursorfile & maskfile arguments for -cursor");
|
||||||
cursor_file = argv[i];
|
cursor_file = argv[i];
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc)
|
||||||
|
usage("missing maskfile argument for -cursor");
|
||||||
cursor_mask = argv[i];
|
cursor_mask = argv[i];
|
||||||
nonexcl++;
|
nonexcl++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-cursor_name", argv[i])) {
|
if (!strcmp("-cursor_name", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("-cursor_name requires an argument");
|
||||||
cursor_name = argv[i];
|
cursor_name = argv[i];
|
||||||
nonexcl++;
|
nonexcl++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-xcf", argv[i])) {
|
if (!strcmp("-xcf", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc)
|
||||||
|
usage("missing cursorfile & cursorsize arguments for -xcf");
|
||||||
xcf = argv[i];
|
xcf = argv[i];
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc)
|
||||||
|
usage("missing cursorsize argument for -xcf");
|
||||||
xcf_size = atoi(argv[i]);
|
xcf_size = atoi(argv[i]);
|
||||||
if (xcf_size <= 0)
|
if (xcf_size <= 0)
|
||||||
xcf_size = 32;
|
xcf_size = 32;
|
||||||
@ -169,17 +175,17 @@ main(int argc, char *argv[])
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-fg",argv[i]) || !strcmp("-foreground",argv[i])) {
|
if (!strcmp("-fg",argv[i]) || !strcmp("-foreground",argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("-foreground requires an argument");
|
||||||
fore_color = argv[i];
|
fore_color = argv[i];
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-bg",argv[i]) || !strcmp("-background",argv[i])) {
|
if (!strcmp("-bg",argv[i]) || !strcmp("-background",argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("-background requires an argument");
|
||||||
back_color = argv[i];
|
back_color = argv[i];
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-solid", argv[i])) {
|
if (!strcmp("-solid", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("-solid requires an argument");
|
||||||
solid_color = argv[i];
|
solid_color = argv[i];
|
||||||
excl++;
|
excl++;
|
||||||
continue;
|
continue;
|
||||||
@ -190,16 +196,16 @@ main(int argc, char *argv[])
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-bitmap", argv[i])) {
|
if (!strcmp("-bitmap", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("-bitmap requires an argument");
|
||||||
bitmap_file = argv[i];
|
bitmap_file = argv[i];
|
||||||
excl++;
|
excl++;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
if (!strcmp("-mod", argv[i])) {
|
if (!strcmp("-mod", argv[i])) {
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("missing x & y arguments for -mod");
|
||||||
mod_x = atoi(argv[i]);
|
mod_x = atoi(argv[i]);
|
||||||
if (mod_x <= 0) mod_x = 1;
|
if (mod_x <= 0) mod_x = 1;
|
||||||
if (++i>=argc) usage();
|
if (++i>=argc) usage("missing y argument for -mod");
|
||||||
mod_y = atoi(argv[i]);
|
mod_y = atoi(argv[i]);
|
||||||
if (mod_y <= 0) mod_y = 1;
|
if (mod_y <= 0) mod_y = 1;
|
||||||
excl++;
|
excl++;
|
||||||
@ -209,14 +215,16 @@ main(int argc, char *argv[])
|
|||||||
reverse = 1;
|
reverse = 1;
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
usage();
|
fprintf(stderr, "%s: unrecognized argument '%s'\n",
|
||||||
|
program_name, argv[i]);
|
||||||
|
usage(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Check for multiple use of exclusive options */
|
/* Check for multiple use of exclusive options */
|
||||||
if (excl > 1) {
|
if (excl > 1) {
|
||||||
fprintf(stderr, "%s: choose only one of {solid, gray, bitmap, mod}\n",
|
fprintf(stderr, "%s: choose only one of {solid, gray, bitmap, mod}\n",
|
||||||
program_name);
|
program_name);
|
||||||
usage();
|
usage(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
dpy = XOpenDisplay(display_name);
|
dpy = XOpenDisplay(display_name);
|
||||||
@ -323,10 +331,13 @@ FixupState(void)
|
|||||||
return;
|
return;
|
||||||
prop = XInternAtom(dpy, "_XSETROOT_ID", False);
|
prop = XInternAtom(dpy, "_XSETROOT_ID", False);
|
||||||
if (unsave_past) {
|
if (unsave_past) {
|
||||||
(void)XGetWindowProperty(dpy, root, prop, 0L, 1L, True, AnyPropertyType,
|
if (XGetWindowProperty(dpy, root, prop, 0L, 1L, True, AnyPropertyType,
|
||||||
&type, &format, &length, &after, &data);
|
&type, &format, &length, &after, &data) != Success)
|
||||||
if ((type == XA_PIXMAP) && (format == 32) &&
|
fprintf(stderr,
|
||||||
(length == 1) && (after == 0))
|
"%s: warning: cannot get _XSETROOT_ID property from root window\n",
|
||||||
|
program_name);
|
||||||
|
else if ((type == XA_PIXMAP) && (format == 32) &&
|
||||||
|
(length == 1) && (after == 0))
|
||||||
XKillClient(dpy, *((Pixmap *)data));
|
XKillClient(dpy, *((Pixmap *)data));
|
||||||
else if (type != None)
|
else if (type != None)
|
||||||
fprintf(stderr, "%s: warning: _XSETROOT_ID property is garbage\n",
|
fprintf(stderr, "%s: warning: _XSETROOT_ID property is garbage\n",
|
||||||
|
Loading…
Reference in New Issue
Block a user