Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
savoirfairelinux
jami-daemon
Commits
3ed30132
Commit
3ed30132
authored
Mar 26, 2009
by
Jérémy Quentin
Browse files
Merge branch 'master' into qt-client
Conflicts: src/managerimpl.cpp
parents
7cd7788a
2ace0800
Changes
61
Hide whitespace changes
Inline
Side-by-side
configure.ac
View file @
3ed30132
...
...
@@ -2,7 +2,7 @@ dnl SFLPhone - configure.ac for automake 1.9 and autoconf 2.59
dnl
dnl Process this file with autoconf to produce a configure script.
AC_PREREQ(2.59)
AC_INIT([SFLphone],[0.9.
3
],[sflphoneteam@savoirfairelinux.com],[sflphone])
AC_INIT([SFLphone],[0.9.
4
],[sflphoneteam@savoirfairelinux.com],[sflphone])
AC_COPYRIGHT([[Copyright (c) Savoir-Faire Linux 2004-2009]])
AC_REVISION([$Revision$])
...
...
@@ -39,7 +39,8 @@ AC_CONFIG_FILES([src/Makefile \
src/dbus/Makefile \
src/plug-in/audiorecorder/Makefile \
src/plug-in/Makefile \
src/plug-in/test/Makefile])
src/plug-in/test/Makefile \
src/hooks/Makefile])
dnl Unitary test section
AC_CONFIG_FILES([test/Makefile])
...
...
@@ -150,6 +151,12 @@ if test "x${have_libpj}" = "xfalse" ; then
fi
AC_SUBST(SIP_CFLAGS)
dnl Check for uuid development package - name: uuid-dev
UUID_MIN_VERSION=1.0
PKG_CHECK_MODULES(UUID, uuid >= ${UUID_MIN_VERSION})
AC_SUBST(UUID_CFLAGS)
AC_SUBST(UUID_LIBS)
dnl Check for alsa development package - name: libasound2-dev
LIBASOUND2_MIN_VERSION=1.0
PKG_CHECK_MODULES(ALSA, alsa >= ${LIBASOUND2_MIN_VERSION})
...
...
@@ -188,18 +195,11 @@ PKG_CHECK_MODULES(DBUSCPP, dbus-c++-1 >= ${LIBDBUSCPP_MIN_VERSION})
AC_SUBST(DBUSCPP_LIBS)
AC_SUBST(DBUSCPP_CFLAGS)
LIBOPENSSL_MIN_VERSION=0.9.8
PKG_CHECK_MODULES(LIBOPENSSL, libssl >= ${LIBOPENSSL_MIN_VERSION})
AC_SUBST(LIBOPENSSL_LIBS)
AC_SUBST(LIBOPENSSL_CFLAGS)
dnl Check for libcppunit-dev
CPPUNIT_MIN_VERSION=1.12
PKG_CHECK_MODULES(CPPUNIT, cppunit >= ${CPPUNIT_MIN_VERSION})
AC_SUBST(CPPUNIT_LIBS)
LIBSSL_MIN_VERSION=0.9.8
# check for libgsm1 (doesn't use pkg-config)
dnl Check for libgsm
AC_ARG_WITH([gsm],
...
...
debian/changelog
View file @
3ed30132
sflphone (0.9.4-0beta1) %system%; urgency=low
[ Alexandre Savard ]
* Display codec used during conversation on the GUI
* Enable/disable STUN parameters at runtime
* Refactor search bar use
[ Emmanuel Milou ]
* Build system fixes
* Implement SIP re-invite
* Implement IP to IP call
[ Julien Bonjean ]
* Integrate GNOME address book based on evolution data server
-- Emmanuel Milou <emmanuel.milou@savoirfairelinux.com> Fri, 20 Mar 2009 18:29:15 -0500
sflphone (0.9.3-0ubuntu3) %system%; urgency=low
[ Alexandre Savard ]
...
...
debian/control.intrepid
View file @
3ed30132
...
...
@@ -2,7 +2,7 @@ Source: sflphone
Maintainer: SavoirFaireLinux Inc <emmanuel.milou@savoirfairelinux.com>
Section: gnome
Priority: optional
Build-Depends: debhelper (>= 5), autoconf, libpulse-dev, libsamplerate0-dev, libcommoncpp2-dev, libccrtp-dev, libcppunit-dev, libgsm1-dev, libspeex-dev, libtool, libgtk2.0-dev, libsexy-dev, libdbus-1-dev, libdbus-glib-1-dev, libnotify-dev, libasound2-dev, libspeexdsp-dev
Build-Depends: debhelper (>= 5), autoconf, libpulse-dev, libsamplerate0-dev, libcommoncpp2-dev, libccrtp-dev, libcppunit-dev, libgsm1-dev, libspeex-dev, libtool, libgtk2.0-dev, libsexy-dev, libdbus-1-dev, libdbus-glib-1-dev, libnotify-dev, libasound2-dev, libspeexdsp-dev
, uuid-dev
Standards-Version: 3.8.0
Package: sflphone
...
...
debian/control.jaunty
View file @
3ed30132
...
...
@@ -2,7 +2,7 @@ Source: sflphone
Maintainer: SavoirFaireLinux Inc <emmanuel.milou@savoirfairelinux.com>
Section: gnome
Priority: optional
Build-Depends: debhelper (>= 5), autoconf, automake, libpulse-dev, libsamplerate0-dev, libcommoncpp2-dev, libccrtp-dev, libcppunit-dev, libgsm1-dev, libspeex-dev, libtool, libgtk2.0-dev, libsexy-dev, libdbus-1-dev, libdbus-glib-1-dev, libnotify-dev, libasound2-dev, libspeexdsp-dev
Build-Depends: debhelper (>= 5), autoconf, automake, libpulse-dev, libsamplerate0-dev, libcommoncpp2-dev, libccrtp-dev, libcppunit-dev, libgsm1-dev, libspeex-dev, libtool, libgtk2.0-dev, libsexy-dev, libdbus-1-dev, libdbus-glib-1-dev, libnotify-dev, libasound2-dev, libspeexdsp-dev
, uuid-dev
Standards-Version: 3.7.3
Package: sflphone
...
...
debian/rules
View file @
3ed30132
...
...
@@ -20,12 +20,12 @@ configure: configure-stamp
configure-stamp
:
dh_testdir
# Add here commands to configure the package.
cd
libs/dbus-c++
;
./autogen.sh
;
./configure
cd
libs/libiax2
;
./gen.sh
;
./configure
cd
libs/pjproject-1.0.1
;
./configure
./autogen.sh
--prefix
=
/usr
--with-debug
cd
sflphone-gtk
;
./autogen.sh
--prefix
=
/usr
cd
libs/pjproject-1.0.1
;
./configure
touch
configure-stamp
cd
libs/dbus-c++
;
./configure
cd
libs/libiax2
;
./configure
#Architecture
...
...
libs/dbus-c++/INSTALL
View file @
3ed30132
Installation
Instructions
*************************
Copyright
(
C
)
1994
,
1995
,
1996
,
1999
,
2000
,
2001
,
2002
,
2004
,
2005
Free
Software
Foundation
,
Inc
.
Copyright
(
C
)
1994
,
1995
,
1996
,
1999
,
2000
,
2001
,
2002
,
2004
,
2005
,
2006
,
2007
Free
Software
Foundation
,
Inc
.
This
file
is
free
documentation
;
the
Free
Software
Foundation
gives
unlimited
permission
to
copy
,
distribute
and
modify
it
.
...
...
@@ -10,7 +10,10 @@ unlimited permission to copy, distribute and modify it.
Basic
Installation
==================
These
are
generic
installation
instructions
.
Briefly
,
the
shell
commands
`./
configure
;
make
;
make
install
' should
configure, build, and install this package. The following
more-detailed instructions are generic; see the `README'
file
for
instructions
specific
to
this
package
.
The
`
configure
' shell script attempts to guess correct values for
various system-dependent variables used during compilation. It uses
...
...
@@ -23,9 +26,9 @@ debugging `configure').
It
can
also
use
an
optional
file
(
typically
called
`
config
.
cache
'
and enabled with `--cache-file=config.cache'
or
simply
`-
C
') that saves
the results of its tests to speed up reconfiguring.
(
Caching is
the results of its tests to speed up reconfiguring. Caching is
disabled by default to prevent problems with accidental use of stale
cache files.
)
cache files.
If you need to do unusual things to compile the package, please try
to figure out how `configure'
could
check
whether
to
do
them
,
and
mail
...
...
@@ -35,20 +38,17 @@ some point `config.cache' contains results you don't want to keep, you
may remove or edit it.
The file `configure.ac'
(
or
`
configure
.
in
') is used to create
`configure'
by
a
program
called
`
autoconf
'. You
only need
`configure.ac'
if
you
want
to
change
it
or
regenerate
`
configure
' using
a newer version
of `autoconf'
.
`configure'
by
a
program
called
`
autoconf
'. You
need `configure.ac'
if
you
want
to
change
it
or
regenerate
`
configure
' using
a newer version
of `autoconf'
.
The
simplest
way
to
compile
this
package
is
:
1.
`
cd
' to the directory containing the package'
s
source
code
and
type
`./
configure
' to configure the package for your system. If you'
re
using
`
csh
' on an old version of System V, you might need to type
`sh ./configure'
instead
to
prevent
`
csh
' from trying to execute
`configure'
itself
.
`./
configure
' to configure the package for your system.
Running
`
configure
' take
s
awhile. While running, it prints
some
messages telling which features it is checking for.
Running `configure'
might
take
a
while
.
While
running
,
it
prints
some
messages
telling
which
features
it
is
checking
for
.
2.
Type
`
make
' to compile the package.
...
...
@@ -67,6 +67,9 @@ The simplest way to compile this package is:
all
sorts
of
other
programs
in
order
to
regenerate
files
that
came
with
the
distribution
.
6.
Often
,
you
can
also
type
`
make
uninstall
' to remove the installed
files again.
Compilers and Options
=====================
...
...
@@ -78,7 +81,7 @@ details on some of the pertinent environment variables.
by
setting
variables
in
the
command
line
or
in
the
environment
.
Here
is
an
example
:
./
configure
CC
=
c
8
9
CFLAGS
=-
O2
LIBS
=-
lposix
./
configure
CC
=
c
9
9
CFLAGS
=-
g
LIBS
=-
lposix
*
Note
Defining
Variables
::,
for
more
details
.
...
...
@@ -87,17 +90,15 @@ Compiling For Multiple Architectures
You
can
compile
the
package
for
more
than
one
kind
of
computer
at
the
same
time
,
by
placing
the
object
files
for
each
architecture
in
their
own
directory
.
To
do
this
,
you
must
use
a
version
of
`
make
' that
supports the `VPATH'
variable
,
such
as
GNU
`
make
'. `cd'
to
the
own
directory
.
To
do
this
,
you
can
use
GNU
`
make
'. `cd'
to
the
directory
where
you
want
the
object
files
and
executables
to
go
and
run
the
`
configure
' script. `configure'
automatically
checks
for
the
source
code
in
the
directory
that
`
configure
' is in and in `..'
.
If
you
have
to
use
a
`
make
' that does not support the `VPATH'
variable
,
you
have
to
compile
the
package
for
one
architecture
at
a
time
in
the
source
code
directory
.
After
you
have
installed
the
package
for
one
architecture
,
use
`
make
distclean
' before reconfiguring
for another architecture.
With
a
non
-
GNU
`
make
', it is safer to compile the package for one
architecture at a time in the source code directory. After you have
installed the package for one architecture, use `make distclean'
before
reconfiguring
for
another
architecture
.
Installation
Names
==================
...
...
@@ -190,12 +191,12 @@ them in the `configure' command line, using `VAR=value'. For example:
./
configure
CC
=/
usr
/
local2
/
bin
/
gcc
causes
the
specified
`
gcc
' to be used as the C compiler (unless it is
overridden
in
the
site
shell
script
).
Here
is
a
another
example
:
overridden in the site shell script).
/
bin
/
bash
./
configure
CONFIG_SHELL
=/
bin
/
bash
Unfortunately, this technique does not work for `CONFIG_SHELL'
due
to
an
Autoconf
bug
.
Until
the
bug
is
fixed
you
can
use
this
workaround
:
Here
the
`
CONFIG_SHELL
=/
bin
/
bash
' operand causes subsequent
configuration-related scripts to be executed by `/bin/bash'
.
CONFIG_SHELL
=/
bin
/
bash
/
bin
/
bash
./
configure
CONFIG_SHELL
=/
bin
/
bash
`
configure
' Invocation
======================
...
...
libs/dbus-c++/depcomp
View file @
3ed30132
#! /bin/sh
# depcomp - compile a program generating dependencies as side-effects
scriptversion
=
200
5-0
7-09.
1
1
scriptversion
=
2007-0
3-2
9.
0
1
# Copyright (C) 1999, 2000, 2003, 2004, 2005 Free Software Foundation, Inc.
# Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007 Free Software
# Foundation, Inc.
# 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
...
...
@@ -91,7 +92,20 @@ gcc3)
## gcc 3 implements dependency tracking that does exactly what
## we want. Yay! Note: for some reason libtool 1.4 doesn't like
## it if -MD -MP comes after the -MF stuff. Hmm.
"
$@
"
-MT
"
$object
"
-MD
-MP
-MF
"
$tmpdepfile
"
## Unfortunately, FreeBSD c89 acceptance of flags depends upon
## the command line argument order; so add the flags where they
## appear in depend2.am. Note that the slowdown incurred here
## affects only configure: in makefiles, %FASTDEP% shortcuts this.
for
arg
do
case
$arg
in
-c
)
set
fnord
"
$@
"
-MT
"
$object
"
-MD
-MP
-MF
"
$tmpdepfile
"
"
$arg
"
;;
*
)
set
fnord
"
$@
"
"
$arg
"
;;
esac
shift
# fnord
shift
# $arg
done
"
$@
"
stat
=
$?
if
test
$stat
-eq
0
;
then
:
else
...
...
@@ -201,34 +215,39 @@ aix)
# current directory. Also, the AIX compiler puts `$object:' at the
# start of each line; $object doesn't have directory information.
# Version 6 uses the directory in both cases.
stripped
=
`
echo
"
$object
"
|
sed
's/\(.*\)\..*$/\1/'
`
tmpdepfile
=
"
$stripped
.u"
dir
=
`
echo
"
$object
"
|
sed
-e
's|/[^/]*$|/|'
`
test
"x
$dir
"
=
"x
$object
"
&&
dir
=
base
=
`
echo
"
$object
"
|
sed
-e
's|^.*/||'
-e
's/\.o$//'
-e
's/\.lo$//'
`
if
test
"
$libtool
"
=
yes
;
then
tmpdepfile1
=
$dir$base
.u
tmpdepfile2
=
$base
.u
tmpdepfile3
=
$dir
.libs/
$base
.u
"
$@
"
-Wc
,-M
else
tmpdepfile1
=
$dir$base
.u
tmpdepfile2
=
$dir$base
.u
tmpdepfile3
=
$dir$base
.u
"
$@
"
-M
fi
stat
=
$?
if
test
-f
"
$tmpdepfile
"
;
then
:
else
stripped
=
`
echo
"
$stripped
"
|
sed
's,^.*/,,'
`
tmpdepfile
=
"
$stripped
.u"
fi
if
test
$stat
-eq
0
;
then
:
else
rm
-f
"
$tmpdepfile
"
rm
-f
"
$tmpdepfile
1
"
"
$tmpdepfile2
"
"
$tmpdepfile3
"
exit
$stat
fi
for
tmpdepfile
in
"
$tmpdepfile1
"
"
$tmpdepfile2
"
"
$tmpdepfile3
"
do
test
-f
"
$tmpdepfile
"
&&
break
done
if
test
-f
"
$tmpdepfile
"
;
then
outname
=
"
$stripped
.o"
# Each line is of the form `foo.o: dependent.h'.
# Do two passes, one to just change these to
# `$object: dependent.h' and one to simply `dependent.h:'.
sed
-e
"s,^
$outname
:,
$object
:,"
<
"
$tmpdepfile
"
>
"
$depfile
"
sed
-e
"s,^
$outname
:
\(
.*
\)
$,
\1
:,"
<
"
$tmpdepfile
"
>>
"
$depfile
"
sed
-e
"s,^.*
\.
[a-z]*:,
$object
:,"
<
"
$tmpdepfile
"
>
"
$depfile
"
# That's a tab and a space in the [].
sed
-e
's,^.*\.[a-z]*:[ ]*,,'
-e
's,$,:,'
<
"
$tmpdepfile
"
>>
"
$depfile
"
else
# The sourcefile does not contain any dependencies, so just
# store a dummy comment line, to avoid errors with the Makefile
...
...
@@ -276,6 +295,46 @@ icc)
rm
-f
"
$tmpdepfile
"
;;
hp2
)
# The "hp" stanza above does not work with aCC (C++) and HP's ia64
# compilers, which have integrated preprocessors. The correct option
# to use with these is +Maked; it writes dependencies to a file named
# 'foo.d', which lands next to the object file, wherever that
# happens to be.
# Much of this is similar to the tru64 case; see comments there.
dir
=
`
echo
"
$object
"
|
sed
-e
's|/[^/]*$|/|'
`
test
"x
$dir
"
=
"x
$object
"
&&
dir
=
base
=
`
echo
"
$object
"
|
sed
-e
's|^.*/||'
-e
's/\.o$//'
-e
's/\.lo$//'
`
if
test
"
$libtool
"
=
yes
;
then
tmpdepfile1
=
$dir$base
.d
tmpdepfile2
=
$dir
.libs/
$base
.d
"
$@
"
-Wc
,+Maked
else
tmpdepfile1
=
$dir$base
.d
tmpdepfile2
=
$dir$base
.d
"
$@
"
+Maked
fi
stat
=
$?
if
test
$stat
-eq
0
;
then
:
else
rm
-f
"
$tmpdepfile1
"
"
$tmpdepfile2
"
exit
$stat
fi
for
tmpdepfile
in
"
$tmpdepfile1
"
"
$tmpdepfile2
"
do
test
-f
"
$tmpdepfile
"
&&
break
done
if
test
-f
"
$tmpdepfile
"
;
then
sed
-e
"s,^.*
\.
[a-z]*:,
$object
:,"
"
$tmpdepfile
"
>
"
$depfile
"
# Add `dependent.h:' lines.
sed
-ne
'2,${; s/^ *//; s/ \\*$//; s/$/:/; p;}'
"
$tmpdepfile
"
>>
"
$depfile
"
else
echo
"#dummy"
>
"
$depfile
"
fi
rm
-f
"
$tmpdepfile
"
"
$tmpdepfile2
"
;;
tru64
)
# The Tru64 compiler uses -MD to generate dependencies as a side
# effect. `cc -MD -o foo.o ...' puts the dependencies into `foo.o.d'.
...
...
@@ -288,13 +347,13 @@ tru64)
if
test
"
$libtool
"
=
yes
;
then
# With Tru64 cc, shared objects can also be used to make a
# static library. This mecanism is used in libtool 1.4 series to
# static library. This mec
h
anism is used in libtool 1.4 series to
# handle both shared and static libraries in a single compilation.
# With libtool 1.4, dependencies were output in $dir.libs/$base.lo.d.
#
# With libtool 1.5 this exception was removed, and libtool now
# generates 2 separate objects for the 2 libraries. These two
# compilations output dependencies in
in
$dir.libs/$base.o.d and
# compilations output dependencies in $dir.libs/$base.o.d and
# in $dir$base.o.d. We have to check for both files, because
# one of the two compilations can be disabled. We should prefer
# $dir$base.o.d over $dir.libs/$base.o.d because the latter is
...
...
libs/dbus-c++/install-sh
View file @
3ed30132
#!/bin/sh
# install - install a program, script, or datafile
scriptversion
=
200
5-05-14.22
scriptversion
=
200
6-12-25.00
# This originates from X11R5 (mit/util/scripts/install.sh), which was
# later released in X11R6 (xc/config/util/install.sh) with the
...
...
@@ -39,38 +39,68 @@ scriptversion=2005-05-14.22
# when there is no Makefile.
#
# This script is compatible with the BSD install script, but was written
# from scratch. It can only install one file at a time, a restriction
# shared with many OS's install programs.
# from scratch.
nl
=
'
'
IFS
=
" ""
$nl
"
# set DOITPROG to echo to test this script
# Don't use :- since 4.3BSD and earlier shells don't like it.
doit
=
"
${
DOITPROG
-
}
"
doit
=
${
DOITPROG
-
}
if
test
-z
"
$doit
"
;
then
doit_exec
=
exec
else
doit_exec
=
$doit
fi
# put in absolute paths if you don't have them in your path; or use env. vars.
# Put in absolute file names if you don't have them in your path;
# or use environment vars.
chgrpprog
=
${
CHGRPPROG
-chgrp
}
chmodprog
=
${
CHMODPROG
-chmod
}
chownprog
=
${
CHOWNPROG
-chown
}
cmpprog
=
${
CMPPROG
-cmp
}
cpprog
=
${
CPPROG
-cp
}
mkdirprog
=
${
MKDIRPROG
-mkdir
}
mvprog
=
${
MVPROG
-mv
}
rmprog
=
${
RMPROG
-rm
}
stripprog
=
${
STRIPPROG
-strip
}
posix_glob
=
'?'
initialize_posix_glob
=
'
test "$posix_glob" != "?" || {
if (set -f) 2>/dev/null; then
posix_glob=
else
posix_glob=:
fi
}
'
mvprog
=
"
${
MVPROG
-mv
}
"
cpprog
=
"
${
CPPROG
-cp
}
"
chmodprog
=
"
${
CHMODPROG
-chmod
}
"
chownprog
=
"
${
CHOWNPROG
-chown
}
"
chgrpprog
=
"
${
CHGRPPROG
-chgrp
}
"
stripprog
=
"
${
STRIPPROG
-strip
}
"
rmprog
=
"
${
RMPROG
-rm
}
"
mkdirprog
=
"
${
MKDIRPROG
-mkdir
}
"
posix_mkdir
=
# Desired mode of installed file.
mode
=
0755
chmodcmd
=
"
$chmodprog
0755"
chowncmd
=
chgrpcmd
=
stripcmd
=
chmodcmd
=
$chmodprog
chowncmd
=
mvcmd
=
$mvprog
rmcmd
=
"
$rmprog
-f"
mvcmd
=
"
$mvprog
"
stripcmd
=
src
=
dst
=
dir_arg
=
dstarg
=
dst_arg
=
copy_on_change
=
false
no_target_directory
=
usage
=
"Usage:
$0
[OPTION]... [-T] SRCFILE DSTFILE
usage
=
"
\
Usage:
$0
[OPTION]... [-T] SRCFILE DSTFILE
or:
$0
[OPTION]... SRCFILES... DIRECTORY
or:
$0
[OPTION]... -t DIRECTORY SRCFILES...
or:
$0
[OPTION]... -d DIRECTORIES...
...
...
@@ -80,81 +110,86 @@ In the 2nd and 3rd, copy all SRCFILES to DIRECTORY.
In the 4th, create DIRECTORIES.
Options:
-c (ignored)
-d create directories instead of installing files.
-g GROUP
$chgrpprog
installed files to GROUP.
-m MODE
$chmodprog
installed files to MODE.
-o USER
$chownprog
installed files to USER.
-s
$stripprog
installed files.
-t DIRECTORY install into DIRECTORY.
-T report an error if DSTFILE is a directory.
--help display this help and exit.
--version display version info and exit.
--help display this help and exit.
--version display version info and exit.
-c (ignored)
-C install only if different (preserve the last data modification time)
-d create directories instead of installing files.
-g GROUP
$chgrpprog
installed files to GROUP.
-m MODE
$chmodprog
installed files to MODE.
-o USER
$chownprog
installed files to USER.
-s
$stripprog
installed files.
-t DIRECTORY install into DIRECTORY.
-T report an error if DSTFILE is a directory.
Environment variables override the default commands:
CHGRPPROG CHMODPROG CHOWNPROG CPPROG MKDIRPROG MVPROG RMPROG STRIPPROG
CHGRPPROG CHMODPROG CHOWNPROG CMPPROG CPPROG MKDIRPROG MVPROG
RMPROG STRIPPROG
"
while
test
-n
"
$1
"
;
do
while
test
$#
-ne
0
;
do
case
$1
in
-c
)
shift
continue
;;
-c
)
;;
-C
)
copy_on_change
=
true
;;
-d
)
dir_arg
=
true
shift
continue
;;
-d
)
dir_arg
=
true
;;
-g
)
chgrpcmd
=
"
$chgrpprog
$2
"
shift
shift
continue
;;
shift
;;
--help
)
echo
"
$usage
"
;
exit
$?
;;
-m
)
chmodcmd
=
"
$chmodprog
$2
"
shift
shift
continue
;;
-m
)
mode
=
$2
case
$mode
in
*
' '
*
|
*
' '
*
|
*
'
'
*
|
*
'*'
*
|
*
'?'
*
|
*
'['
*
)
echo
"
$0
: invalid mode:
$mode
"
>
&2
exit
1
;;
esac
shift
;;
-o
)
chowncmd
=
"
$chownprog
$2
"
shift
shift
continue
;;
shift
;;
-s
)
stripcmd
=
$stripprog
shift
continue
;;
-s
)
stripcmd
=
$stripprog
;;
-t
)
dstarg
=
$2
shift
shift
continue
;;
-t
)
dst_arg
=
$2
shift
;;
-T
)
no_target_directory
=
true
shift
continue
;;
-T
)
no_target_directory
=
true
;;
--version
)
echo
"
$0
$scriptversion
"
;
exit
$?
;;
*
)
# When -d is used, all remaining arguments are directories to create.
# When -t is used, the destination is already specified.
test
-n
"
$dir_arg$dstarg
"
&&
break
# Otherwise, the last argument is the destination. Remove it from $@.
for
arg
do
if
test
-n
"
$dstarg
"
;
then
# $@ is not empty: it contains at least $arg.
set
fnord
"
$@
"
"
$dstarg
"
shift
# fnord
fi
shift
# arg
dstarg
=
$arg
done
--
)
shift
break
;;
-
*
)
echo
"
$0
: invalid option:
$1
"
>
&2
exit
1
;;
*
)
break
;;
esac
shift
done
if
test
-z
"
$1
"
;
then
if
test
$#
-ne
0
&&
test
-z
"
$dir_arg$dst_arg
"
;
then
# When -d is used, all remaining arguments are directories to create.
# When -t is used, the destination is already specified.
# Otherwise, the last argument is the destination. Remove it from $@.
for
arg
do
if
test
-n
"
$dst_arg
"
;
then
# $@ is not empty: it contains at least $arg.
set
fnord
"
$@
"
"
$dst_arg
"
shift
# fnord
fi
shift
# arg
dst_arg
=
$arg
done
fi
if
test
$#
-eq
0
;
then
if
test
-z
"
$dir_arg
"
;
then
echo
"
$0
: no input file specified."
>
&2
exit
1
...
...
@@ -164,24 +199,47 @@ if test -z "$1"; then
exit
0
fi
if
test
-z
"
$dir_arg
"
;
then
trap
'(exit $?); exit'
1 2 13 15
# Set umask so as not to create temps with too-generous modes.
# However, 'strip' requires both read and write access to temps.
case
$mode
in
# Optimize common cases.
*
644
)
cp_umask
=
133
;;
*
755
)
cp_umask
=
22
;;
*
[
0-7]
)
if
test
-z
"
$stripcmd
"
;
then
u_plus_rw
=
else
u_plus_rw
=
'% 200'
fi
cp_umask
=
`
expr
'('
777 -
$mode
% 1000
')'
$u_plus_rw
`
;;
*
)
if
test
-z
"
$stripcmd
"
;
then
u_plus_rw
=