Wykres commitów

176 Commity (dcae93ab3914bb1411395c1356fd58722d6279c4)

Autor SHA1 Wiadomość Data
chris@cnpbagwell.com 07c5723cab Merge branch 'master' of ssh://cbagwell-guest@git.debian.org/git/sane/sane-backends 2009-05-09 21:40:55 -05:00
chris@cnpbagwell.com 4d9e8138af standardize including local sane/ include files.
Source code was inconsistent on how they were referencing
include files in include/sane.  In certain cases, sane/sane.h
and sane/saneopts.h was really including external copies (with
some preprocessor implementations anyways).
2009-05-07 22:06:20 -05:00
Julien BLACHE d92a20febb Close network fds in the Avahi process
Network fds are of no use to the Avahi process and can cause the net
backend to hang when saned is run in debug mode.

This only happens if the net backend tries to connect to saned a second
time and manages to establish the connection before saned has completed
its shutdown.

There is some potential for this to also occur when saned is run in
standalone mode but it's far less probable as the window is a lot smaller.
2009-05-06 11:38:16 +02:00
m. allan noah 764aa7c6e1 add more generated files to .gitignore 2009-05-05 15:56:54 -04:00
Julien BLACHE 6e4ed52293 Add basic .gitignore files 2009-05-04 14:45:17 +02:00
Chris Bagwell 6b5973313c * Makefile.in, aclocal.m4, configure, */Makefile.in: Regenerated
with newer automake.
* backend/Makefile.am, tools/sane-config.in: Add missing
$GPHOTO2_LDFLAGS so library can be found.
* tools/Makefile.am: Add mising $SCSI_LIBS to sane-find-scanner.
2009-05-03 22:01:23 +00:00
m. allan noah 0342a63033 Updates to prepare for 1.0.20 release:
* configure.in: change version to 1.0.20cvs
* configure: rebuild from configure.in
* include/sane/sane.h: hide API changes (minor, frame and status)
* backend/canon_dr.c, backend/fujitsu.c: SANE_FRAME_JPEG
* backend/coolscan3.c: SANE_FRAME_RGBI
* backend/genesys_gl646.c, backend/genesys_gl841.c: STATUS_HW_LOCKED
* backend/rts8891.c, frontend/scanimage.c: STATUS_WARMING_UP
* backend/pixma_io_sanei.c, backend/xerox_mfp.c,
  backend/sane_strstatus.c: STATUS_HW_LOCKED & STATUS_WARMING_UP
* doc/releases.txt: minor updates for new build system
2009-04-12 19:40:31 +00:00
m. allan noah 1636ba5334 * frontend/scanimage.c, doc/scanimage.man: make -B (buffer-size)
selectable, and make long name consistent. (#309672 by Johannes Berg)
2009-03-14 18:10:38 +00:00
Julien BLACHE f29d2ac068 Explicitly bind IPv6 addresses first. 2009-03-13 17:02:25 +00:00
Ilia Sotnikov 2ddc741dac - Remove unnecessary 'res' variable assignment in check_host()
(AF-indep version)
2009-03-13 11:43:57 +00:00
Julien BLACHE 9cdf75633d Rework Ilia's changes in check_host(). 2009-03-13 08:59:31 +00:00
Ilia Sotnikov 6940d841eb * Allow host checking to proceed if no local name was found 2009-03-12 15:54:00 +00:00
Ilia Sotnikov d32a9420da * Use hstrerror (h_errno) instead of strerror(errno) on gethostbyname()
errors
2009-03-12 12:41:46 +00:00
Chris Bagwell 9d1375fd7e * acinclude.m4, tools/sane-config.in: Add in missing libraries
to sane-config missed during fix to stop using LIBS to link everything.
Add back in code to move LDFLAGS out of $GPHOTO2_LIBS and into
GPHOTO2_LDFLAGS.
2009-03-03 02:53:42 +00:00
Julien BLACHE b72c29cd75 Make sure backends can't break the network dialog and crash the remote net
backend by writing to stdin/stdout/stderr.
2009-03-02 11:21:52 +00:00
Chris Bagwell 70f3fdfba4 * acinclude.m4, backend/*.[ch], tools/*.[ch], frontend/*.[ch]:
Global replace of u_int??_t with C9x standard based uintxx_t
 in order to remove some tricky and overlapping portability logic
 from acinclude.m4 and leave it in only m4/stdint.m4.
2009-02-26 03:15:43 +00:00
m. allan noah c290bb2e1b * frontend/scanimage.c: improved comments, simplified x/y option code,
removed buggy -1/+1 x/y code (#311172), expose non-settable options,
check for invalid caps on options, handle option descs with \n
* doc/releases.txt: add note about cvs checkout on alioth.
2009-02-25 03:29:14 +00:00
Chris Bagwell be3f46204b * po/Makefile.am, configure.in: convert remaining directory,
po, to use automake.
2009-02-21 22:45:14 +00:00
Mattias Ellert 18e9d6c358 Restore alloca include order 2009-02-20 17:56:54 +00:00
Mattias Ellert 0827226249 Adding missing liblib dependencies 2009-02-20 16:51:09 +00:00
Chris Bagwell cb4fb37eca Have configure define configdir so all makefiles can use
it (fixes bug introduce with sanei converted to automake).
Enable running testsuite during distcheck.
2009-02-19 18:10:12 +00:00
Chris Bagwell e380729334 * configure.in, tools/Makefile.am: convert tools to automake.
Add tools/openbsd to distribution package.
* include/Makefile.am: include files should have been installed
under sane/ directory when converted to automake.
* doc/Makefile.am: Cleanup. Use automake's built in support to
install docs within subdirectories.
2009-02-19 02:17:45 +00:00
Julien BLACHE 25818023c6 Fix handling of Avahi server restart. 2009-02-18 13:19:51 +00:00
Chris Bagwell aef46252cc convert frontend, include, and sanei directories to use
automake.  Only reference libsanei.la now. Use am_conditional
to compile sanei_jpeg.lo.  distcheck now runs sanei/wire_test.
2009-02-15 03:31:36 +00:00
Chris Bagwell caba90c552 * configure.in, acinclude.ac: Cleanup autoconf 2.63 warnings.
add cv_ prefix to cached variable.  Remove AC_ARG_PROGRAM as
automake already invokes this. When prefered AC_USE_SYSTEM_EXTENSIONS
exists, use that instead of AC_GNU_SOURCE/AC_AIX/AC_MINUX.
Cleanup socket detection more by creating only a single
SOCKET_LIBS that contains list of all optional libraries
for any socket related funciton.  Make sure that checks
for socket related functions use SOCKET_LIBS when searching.
Check for getopt_long() and getopt.h.  Make OS/2 use
-no-undefined (same as windows).
* ltmain.sh, m4/libtool.m4: Upgrade to libtool 1.5.26.
* Makefile.am: Cleanups to match configure updates.
* frontend/scanimage.c, include/Makefile.in, lib/getopt.c
lib/getopt1.c, toosl/sane-desc.c, include/lgetopt.h:
Rename internal getopt.h to lgetopt.h to allow using
external getopt.h when it exists.  This allows to go
back to optionally compiling getopt()/getopt_long() and its
prototypes and not have conflicts with external headers/symbols.
2009-02-06 03:10:44 +00:00
Chris Bagwell 0330a4d416 * aclocalm4: fix prototype of internal strcasestr and usleep.
* configure.in: Group all USB logic together and all SCSI
logic together to aid understanding of whats no longer
valid.  Allow sharing enable/disable options between all
USB drivers on multiple platforms.  Combined CAM_LIBS and
SCSI_LIBS since they are mutually exclusive.
Skip some USB/SCSI checks when previous tests show it will always fail.
* backend/Makefile.am, tools/Makefile.in: Combine CAM_LIBS and
SCSI_LIBS. Add missing SOCKET_LIBS to epson2.  Add USB_LIB.
* saned.c: Add limits.h for PATH_MAX.
2009-02-02 03:17:32 +00:00
Chris Bagwell 23ff26f9a5 * acinclude.m4, configure.in: Put all libraries into their
own *_LIB variables instead of $LIB so that we do not have to
link in the world to all executables. Modified SANE_CHECK_U_TYPES
to be a little more portable to platforms that use #define
for u_* types. Create SANE_CHECK_BACKENDS macro so that
PRELOADABLE_BACKENDS can also be valided.  Auto-populated
PRELAODABLE_BACKENDS when detect dlopen() won't work.
Various protability cleanups.
* backend/dll.c: Make dll-preload.c a .h since its an include and
not compilable byitself.
* frontend/Makefile.in, frontend/scanimage.c, include/laaloca.h,
  lib/Makefile.am, lib/alloca.c, strcasestr.c, tools/Makefile.in,
  tools/sane-desc.c: Convert lib/ to automake.  Create a liblib.la
  for everyone to use and a libfelib.la for only frontend programs.
  Make all internal programs be prefixed with sanei_ as not to conflict
  with other programs libsane is linked in with that will also most
  likely create similar internal utils on problem platforms.
  * include/getopt.h, lib/getopt.c, lib/getopt1.c: Always compile
  and link in getopt_long() but prefix it with sanei_.  Its
  easier to always use internal version then try to figure out what
  platforms support getopt_long() and what header files to use.
  * backend/Makefile.am: Convert backend makefile to automake.
  Initial version that is feature parity with original but uses
  specific rules instead of wildcards and only links in libraries/objs
  really required. Room for more cleanup of whats linked in once
  all makefiles have been converted to automake.
2009-01-31 03:12:18 +00:00
Chris Bagwell 907cbe7ac6 Replace usage of getgrouplist() with
getgrent() and friends.  getgrouplist is not posix and not
on several platforms including cygwin.
2009-01-31 02:18:41 +00:00
Chris Bagwell b52b0c0c14 * backend/epson2.c backend/pixma_bjnp.c, include/sane/sanei_backend.h,
sanei/sanei_tcp.c, sanie/sanei_udp.c: Improve portablity by
  removing usage of MSG_WAITALL since not all platforms support
  that (cygwin).  Default is to be blocking anyways.  Changed
  usage of MSG_NOTWAIT to use fcntl() function as needed as well.
  * configure.in, lib/Makefile.in, lib/strcasestr.c: Add internal
  strcasestr() for platforms missing it (cygwin).
  * pixma_common.c: My source match header prototype for picky
  compilers (cygwin).
  * backend/umax_pp_mid.c: Allow BACKEND_NAME to be filename
  yet debug to be SANE_DEBUG_UMAX_PP to match man page.
2009-01-29 15:10:19 +00:00
Julien BLACHE a42b57186f Make batch mode create output files atomically. 2009-01-17 10:18:40 +00:00
Chris Bagwell c90e23a6d2 Updates to Makefiles to prepare for transition to automake.
Fix a few bugs with "all" and "uninstall" targets to work when
$(builddir) != $(srcdir).  Added $(DESTDIR) to uninstall target.
Made $(distdir) related to current directory to match automake.
2009-01-16 23:39:48 +00:00
Julien BLACHE b9807541c7 Add a data_portrange configuration file option to saned. 2008-12-12 15:51:15 +00:00
Julien BLACHE 3dfc5881ea Fix crasher typo in IPv4-only code. 2008-12-12 15:29:59 +00:00
Julien BLACHE 383947f31d Fix erroneous comment. 2008-12-12 15:29:10 +00:00
m. allan noah 425a3d034d * backend/fujitsu.[ch]: backend v85
- round pixels_per_line down to arbitrary limits for fi-4990 & fi-4860
 - fi-4860 returns random garbage to serial number queries
 - initialize *info to 0 in sane_control_option()
* doc/descriptions/fujitsu.desc: backend v85, improve status/comments
* frontend/scanimage.c: initialize *info, fix buffer overwalk
2008-12-10 21:32:10 +00:00
m. allan noah ba856d2aec 2008-09-25 m. allan noah <kitno455 a t gmail d o t com>
* include/sane/saneopts.h: underscore not allowed in option names
        * frontend/scanimage.c: fix broken unknown length (-1) binary scans,
          fix invalid tiff height with unknown length scans, fix compiler warn
2008-09-25 02:39:52 +00:00
Julien BLACHE 9f7441d267 Initialize ngroups to 0, ditto for runas_{u,g}id (instead of -1). 2008-08-05 09:27:39 +00:00
Julien BLACHE eefb1b1155 Get option descriptor 0 before trying to read the value for option 0. 2008-08-04 20:54:10 +00:00
Julien BLACHE 32b343dcea Set supplemental group list in addition to setting euid and egid. Reported by Cameron Hutchison. 2008-07-31 09:42:33 +00:00
Julien BLACHE 125ed414d4 Call setegid() before seteuid(), aka while we're still root. 2008-07-28 10:48:41 +00:00
Julien BLACHE 0ec211ef87 Rework error/exit path in process_request() to properly terminate the Avahi thread in debug mode. 2008-06-24 19:41:44 +00:00
Julien BLACHE 83365608d3 Terminate child processes before exiting in debug mode. 2008-06-22 08:47:59 +00:00
Julien BLACHE dd6537cf0a Fix function name in debug message. 2008-06-22 08:41:51 +00:00
m. allan noah 0acce974b2 add %n (newline) to -f option 2008-05-28 00:48:21 +00:00
Stéphane Voltz 78fc186543 - handling of SANE_STATUS_WARMING_UP 2008-05-26 04:56:41 +00:00
m. allan noah 084a18b0c4 remove undocumented and otherwise unused SANE_CAP_ALWAYS_SETTABLE 2008-05-21 01:20:35 +00:00
Julien BLACHE fde1551f68 Fix typo. 2008-04-13 14:21:59 +00:00
Julien BLACHE eff4892c1c Restrict protocol for service announcement/browsing/resolution to IPv4
unless IPv6 is enabled.
2008-04-11 17:43:16 +00:00
Julien BLACHE f4ff1b74f6 Add mDNS DNS-SD support to saned and the net backend so they can announce
and discover each other automatically.

Optional at configure time, requires Avahi >= 0.6.4.
2008-04-11 17:18:19 +00:00
Julien BLACHE 90a1c88e0d saned can now drop privileges when running in standalone mode. 2008-04-10 16:55:36 +00:00