LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
Search this Thread
Old 09-30-2007, 07:06 AM   #1
webdevel
Member
 
Registered: Jan 2005
Location: Moldova
Distribution: Gentoo / Athlon 3200 / RAM 512
Posts: 60

Rep: Reputation: 15
Unhappy Compilation error: sane-backends


I'm running Gentoo with last portage tree. A lot of software works perfectly. But when I try to compile sane-backends I get very strange error:

getenv.c:13:4: error: #error "Missing getenv() on this platform. Please implement."
getenv.c: In function 'getenv'


Please, can anybody who have Gentoo try to emerge sane-backends ?

I did try to compile with and without SANE_BACKENDS variable, USE=usb, emerge and manual ./configure returns the same getenv() error.
But my system have standart stdlib.h getenv() function !!!
Where is a problem ?




----------------------------------------------------------------------
Here is the configuration report:

>>> Unpacking sane-backends-1.0.18.tar.gz to /usr/tmp/portage/media-gfx/sane-backends-1.0.18-r4/work
>>> Unpacking sane-1.0.18-brother-driver.diff.bz2 to /usr/tmp/portage/media-gfx/sane-backends-1.0.18-r4/work
>>> Unpacking sane-1.0.18-brother-driver.diff.bz2 to /usr/tmp/portage/media-gfx/sane-backends-1.0.18-r4/work
* Applying sane-1.0.18-brother-driver.diff ... [ ok ]
* Applying udev-rule-3.patch ... [ ok ]
* Applying broken_coolscan.patch ... [ ok ]
>>> Source unpacked.
>>> Compiling source in /usr/tmp/portage/media-gfx/sane-backends-1.0.18-r4/work/sane-backends-1.0.18 ...
* econf: updating sane-backends-1.0.18/config.guess with /usr/share/gnuconfig/config.guess
* econf: updating sane-backends-1.0.18/config.sub with /usr/share/gnuconfig/config.sub
./configure --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man --infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc --localstatedir=/var/lib --enable-libusb --without-gphoto2 --disable-ipv6 --build=i686-pc-linux-gnu
checking build system type... i686-pc-linux-gnu
checking host system type... i686-pc-linux-gnu
checking for i686-pc-linux-gnu-gcc... i686-pc-linux-gnu-gcc
checking for C compiler default output file name... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether i686-pc-linux-gnu-gcc accepts -g... yes
checking for i686-pc-linux-gnu-gcc option to accept ISO C89... none needed
checking for a BSD-compatible install... /usr/bin/install -c
checking whether make sets $(MAKE)... yes
checking how to run the C preprocessor... i686-pc-linux-gnu-gcc -E
checking for grep that handles long lines and -e... /bin/grep
checking for egrep... /bin/grep -E
checking whether i686-pc-linux-gnu-gcc needs -traditional... no
checking for sane-config... no
checking for msgfmt... /usr/bin/msgfmt
checking for xgettext... /usr/bin/xgettext
checking for msgmerge... /usr/bin/msgmerge
checking for latex... no
checking for dvips... no
checking for makeindex... no
checking for makedepend... /usr/bin/makedepend
checking linker parameter to set runtime link path... -Wl,-rpath,
checking for AIX... no
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking minix/config.h usability... no
checking minix/config.h presence... no
checking for minix/config.h... no
checking for library containing strerror... none required
checking mach-o/dyld.h usability... no
checking mach-o/dyld.h presence... no
checking for mach-o/dyld.h... no
checking dlfcn.h usability... yes
checking dlfcn.h presence... yes
checking for dlfcn.h... yes
checking for dlopen in -ldl... yes
checking for dlopen... yes
checking dl.h usability... no
checking dl.h presence... no
checking for dl.h... no
checking for sqrt in -lm... yes
checking for scsireq_enter in -lscsi... no
checking for cam_open_device in -lcam... no
checking for library containing gethostbyaddr... none required
checking for library containing socket... none required
checking for library containing syslog... none required
checking for jpeg_start_decompress in -ljpeg... yes
checking jconfig.h usability... yes
checking jconfig.h presence... yes
checking for jconfig.h... yes
checking for jpeglib - version >= 61 (6a)... yes
checking for TIFFFdOpen in -ltiff... yes
checking tiffio.h usability... yes
checking tiffio.h presence... yes
checking for tiffio.h... yes
checking ieee1284.h usability... yes
checking ieee1284.h presence... yes
checking for ieee1284.h... yes
checking for libieee1284 >= 0.1.5... yes
checking pthread.h usability... yes
checking pthread.h presence... yes
checking for pthread.h... yes
checking for pthread_create in -lpthread... no
checking for pthread_create... no
checking for pthread_kill... no
checking for pthread_join... no
checking for pthread_detach... no
checking for pthread_cancel... no
checking for pthread_testcancel... no
checking whether to enable pthread support... no
checking whether to use pthread instead of fork... no
checking whether to enable device locking... yes
configure: Setting lockdir group to uucp
checking for sane_init in -lsane... no
checking for ANSI C header files... (cached) yes
checking fcntl.h usability... yes
checking fcntl.h presence... yes
checking for fcntl.h... yes
checking for unistd.h... (cached) yes
checking libc.h usability... no
checking libc.h presence... no
checking for libc.h... no
checking sys/dsreq.h usability... no
checking sys/dsreq.h presence... no
checking for sys/dsreq.h... no
checking sys/select.h usability... yes
checking sys/select.h presence... yes
checking for sys/select.h... yes
checking sys/time.h usability... yes
checking sys/time.h presence... yes
checking for sys/time.h... yes
checking sys/shm.h usability... yes
checking sys/shm.h presence... yes
checking for sys/shm.h... yes
checking sys/ipc.h usability... yes
checking sys/ipc.h presence... yes
checking for sys/ipc.h... yes
checking sys/signal.h usability... yes
checking sys/signal.h presence... yes
checking for sys/signal.h... yes
checking sys/scanio.h usability... no
checking sys/scanio.h presence... no
checking for sys/scanio.h... no
checking scsi.h usability... no
checking scsi.h presence... no
checking for scsi.h... no
checking sys/scsi.h usability... no
checking sys/scsi.h presence... no
checking for sys/scsi.h... no
checking sys/scsicmd.h usability... no
checking sys/scsicmd.h presence... no
checking for sys/scsicmd.h... no
checking sys/scsiio.h usability... no
checking sys/scsiio.h presence... no
checking for sys/scsiio.h... no
checking bsd/dev/scsireg.h usability... no
checking bsd/dev/scsireg.h presence... no
checking for bsd/dev/scsireg.h... no
checking scsi/sg.h usability... yes
checking scsi/sg.h presence... yes
checking for scsi/sg.h... yes
checking /usr/src/linux/include/scsi/sg.h usability... no
checking /usr/src/linux/include/scsi/sg.h presence... no
checking for /usr/src/linux/include/scsi/sg.h... no
checking camlib.h usability... no
checking camlib.h presence... no
checking for camlib.h... no
checking os2.h usability... no
checking os2.h presence... no
checking for os2.h... no
checking sys/socket.h usability... yes
checking sys/socket.h presence... yes
checking for sys/socket.h... yes
checking sys/io.h usability... yes
checking sys/io.h presence... yes
checking for sys/io.h... yes
checking gscdds.h usability... no
checking gscdds.h presence... no
checking for gscdds.h... no
checking sys/hw.h usability... no
checking sys/hw.h presence... no
checking for sys/hw.h... no
checking for sys/types.h... (cached) yes
checking sys/scsi/scsi.h usability... no
checking sys/scsi/scsi.h presence... no
checking for sys/scsi/scsi.h... no
checking sys/scsi/sgdefs.h usability... no
checking sys/scsi/sgdefs.h presence... no
checking for sys/scsi/sgdefs.h... no
checking sys/scsi/targets/scgio.h usability... no
checking sys/scsi/targets/scgio.h presence... no
checking for sys/scsi/targets/scgio.h... no
checking apollo/scsi.h usability... no
checking apollo/scsi.h presence... no
checking for apollo/scsi.h... no
checking sys/sdi_comm.h usability... no
checking sys/sdi_comm.h presence... no
checking for sys/sdi_comm.h... no
checking sys/passthrudef.h usability... no
checking sys/passthrudef.h presence... no
checking for sys/passthrudef.h... no
checking linux/ppdev.h usability... yes
checking linux/ppdev.h presence... yes
checking for linux/ppdev.h... yes
checking dev/ppbus/ppi.h usability... no
checking dev/ppbus/ppi.h presence... no
checking for dev/ppbus/ppi.h... no
checking machine/cpufunc.h usability... no
checking machine/cpufunc.h presence... no
checking for machine/cpufunc.h... no
checking usb.h usability... yes
checking usb.h presence... yes
checking for usb.h... yes
checking sys/bitypes.h usability... yes
checking sys/bitypes.h presence... yes
checking for sys/bitypes.h... yes
checking sys/sem.h usability... yes
checking sys/sem.h presence... yes
checking for sys/sem.h... yes
checking sys/poll.h usability... yes
checking sys/poll.h presence... yes
checking for sys/poll.h... yes
checking IOKit/cdb/IOSCSILib.h usability... no
checking IOKit/cdb/IOSCSILib.h presence... no
checking for IOKit/cdb/IOSCSILib.h... no
checking IOKit/scsi-commands/SCSICommandOperationCodes.h usability... no
checking IOKit/scsi-commands/SCSICommandOperationCodes.h presence... no
checking for IOKit/scsi-commands/SCSICommandOperationCodes.h... no
checking windows.h usability... no
checking windows.h presence... no
checking for windows.h... no
checking be/kernel/OS.h usability... no
checking be/kernel/OS.h presence... no
checking for be/kernel/OS.h... no
checking be/drivers/USB_scanner.h usability... no
checking be/drivers/USB_scanner.h presence... no
checking for be/drivers/USB_scanner.h... no
checking limits.h usability... yes
checking limits.h presence... yes
checking for limits.h... yes
checking sys/ioctl.h usability... yes
checking sys/ioctl.h presence... yes
checking for sys/ioctl.h... yes
checking asm/types.h usability... yes
checking asm/types.h presence... yes
checking for asm/types.h... yes
checking for asm/io.h... no
checking for io/cam/cam.h... no
checking resmgr.h usability... no
checking resmgr.h presence... no
checking for resmgr.h... no
checking for usbcalls.h... no
checking return type of signal handlers... void
checking for size_t... yes
checking for pid_t... yes
checking for ssize_t... yes
checking for u_int8_t only in sys/bitypes.h... no, also in standard headers
checking for u_int8_t... yes
checking for u_int16_t... yes
checking for u_int32_t... yes
checking for u_char... yes
checking for u_int... yes
checking for u_long... yes
checking for long long support... yes
checking for socklen_t in <sys/socket.h>... yes
checking for union semun in <sys/sem.h>... no
checking for sg_header.target_status in <scsi/sg.h>... yes
checking for struct flock in fcntl.h... yes
checking for Linux ioctl defines... yes
checking whether byte ordering is bigendian... no
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking for working alloca.h... no
checking for alloca... no
checking whether `alloca.c' needs Cray hooks... no
checking stack direction for C alloca... -1
checking for stdlib.h... (cached) yes
checking for unistd.h... (cached) yes
checking for getpagesize... no
checking for working mmap... no
checking for atexit... no
checking for inet_addr... no
checking for inet_aton... no
checking for inet_ntoa... no
checking for ioperm... no
checking for i386_set_ioperm... no
checking for mkdir... no
checking for scsireq_enter... no
checking for strftime... no
checking for strstr... no
checking for strtod... no
checking for cfmakeraw... no
checking for tcsendbreak... no
checking for strcasecmp... no
checking for strncasecmp... no
checking for _portaccess... no
checking for getaddrinfo... no
checking for getnameinfo... no
checking for poll... no
checking for setitimer... no
checking for iopl... no
checking for getenv... no
checking for inet_ntop... no
checking for inet_pton... no
checking for isfdtype... no
checking for sigprocmask... no
checking for snprintf... no
checking for strdup... no
checking for strndup... no
checking for strsep... no
checking for usleep... no
checking for vsyslog... no
checking for usb_interrupt_read in -lusb... no
checking for a sed that does not truncate output... /bin/sed
checking for ld used by i686-pc-linux-gnu-gcc... /usr/i686-pc-linux-gnu/bin/ld
checking if the linker (/usr/i686-pc-linux-gnu/bin/ld) is GNU ld... yes
checking for /usr/i686-pc-linux-gnu/bin/ld option to reload object files... -r
checking for BSD-compatible nm... /usr/bin/i686-pc-linux-gnu-nm -B
checking whether ln -s works... yes
checking how to recognise dependent libraries... pass_all
checking for dlfcn.h... (cached) yes
checking for i686-pc-linux-gnu-g++... i686-pc-linux-gnu-g++
checking whether we are using the GNU C++ compiler... yes
checking whether i686-pc-linux-gnu-g++ accepts -g... yes
checking how to run the C++ preprocessor... i686-pc-linux-gnu-g++ -E
checking for i686-pc-linux-gnu-g77... no
checking for i686-pc-linux-gnu-f77... no
checking for i686-pc-linux-gnu-xlf... no
checking for i686-pc-linux-gnu-frt... no
checking for i686-pc-linux-gnu-pgf77... no
checking for i686-pc-linux-gnu-cf77... no
checking for i686-pc-linux-gnu-fort77... no
checking for i686-pc-linux-gnu-fl32... no
checking for i686-pc-linux-gnu-af77... no
checking for i686-pc-linux-gnu-f90... no
checking for i686-pc-linux-gnu-xlf90... no
checking for i686-pc-linux-gnu-pgf90... no
checking for i686-pc-linux-gnu-pghpf... no
checking for i686-pc-linux-gnu-epcf90... no
checking for i686-pc-linux-gnu-gfortran... i686-pc-linux-gnu-gfortran
checking whether we are using the GNU Fortran 77 compiler... yes
checking whether i686-pc-linux-gnu-gfortran accepts -g... yes
checking the maximum length of command line arguments... 32768
checking command to parse /usr/bin/i686-pc-linux-gnu-nm -B output from i686-pc-linux-gnu-gcc object... ok
checking for objdir... .libs
checking for i686-pc-linux-gnu-ar... i686-pc-linux-gnu-ar
checking for i686-pc-linux-gnu-ranlib... i686-pc-linux-gnu-ranlib
checking for i686-pc-linux-gnu-strip... i686-pc-linux-gnu-strip
checking if i686-pc-linux-gnu-gcc static flag works... no
checking if i686-pc-linux-gnu-gcc supports -fno-rtti -fno-exceptions... no
checking for i686-pc-linux-gnu-gcc option to produce PIC... -fPIC
checking if i686-pc-linux-gnu-gcc PIC flag -fPIC works... yes
checking if i686-pc-linux-gnu-gcc supports -c -o file.o... yes
checking whether the i686-pc-linux-gnu-gcc linker (/usr/i686-pc-linux-gnu/bin/ld) supports shared libraries... yes
checking whether -lc should be explicitly linked in... no
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
configure: creating libtool
appending configuration tag "CXX" to libtool
checking for ld used by i686-pc-linux-gnu-g++... /usr/i686-pc-linux-gnu/bin/ld
checking if the linker (/usr/i686-pc-linux-gnu/bin/ld) is GNU ld... yes
checking whether the i686-pc-linux-gnu-g++ linker (/usr/i686-pc-linux-gnu/bin/ld) supports shared libraries... yes
checking for i686-pc-linux-gnu-g++ option to produce PIC... -fPIC
checking if i686-pc-linux-gnu-g++ PIC flag -fPIC works... yes
checking if i686-pc-linux-gnu-g++ supports -c -o file.o... yes
checking whether the i686-pc-linux-gnu-g++ linker (/usr/i686-pc-linux-gnu/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
appending configuration tag "F77" to libtool
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
checking for i686-pc-linux-gnu-gfortran option to produce PIC... -fPIC
checking if i686-pc-linux-gnu-gfortran PIC flag -fPIC works... yes
checking if i686-pc-linux-gnu-gfortran supports -c -o file.o... yes
checking whether the i686-pc-linux-gnu-gfortran linker (/usr/i686-pc-linux-gnu/bin/ld) supports shared libraries... yes
checking dynamic linker characteristics... GNU/Linux ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
*** disabling GPHOTO2 backend (not requested, or failed to find required libraries)
*** disabling PINT backend (sys/scanio.h not found)
*** disabling qcam backend (ioperm or portaccess not found)
*** disabling MUSTEK_USB2 backend (failed to find pthread library)
*** disabling pnm backend (not selected manually)
scsi buffersize: 131072
enabling translations
configure: creating ./config.status
config.status: creating Makefile
config.status: WARNING: Makefile.in seems to ignore the --datarootdir setting
config.status: creating lib/Makefile
config.status: WARNING: lib/Makefile.in seems to ignore the --datarootdir setting
config.status: creating sanei/Makefile
config.status: WARNING: sanei/Makefile.in seems to ignore the --datarootdir setting
config.status: creating frontend/Makefile
config.status: WARNING: frontend/Makefile.in seems to ignore the --datarootdir setting
config.status: creating japi/Makefile
config.status: WARNING: japi/Makefile.in seems to ignore the --datarootdir setting
config.status: creating backend/Makefile
config.status: WARNING: backend/Makefile.in seems to ignore the --datarootdir setting
config.status: creating include/Makefile
config.status: WARNING: include/Makefile.in seems to ignore the --datarootdir setting
config.status: creating doc/Makefile
config.status: WARNING: doc/Makefile.in seems to ignore the --datarootdir setting
config.status: creating po/Makefile
config.status: WARNING: po/Makefile.in seems to ignore the --datarootdir setting
config.status: creating testsuite/Makefile
config.status: WARNING: testsuite/Makefile.in seems to ignore the --datarootdir setting
config.status: creating tools/Makefile
config.status: WARNING: tools/Makefile.in seems to ignore the --datarootdir setting
config.status: creating doc/doxygen-sanei.conf
config.status: creating tools/sane-config
config.status: WARNING: tools/sane-config.in seems to ignore the --datarootdir setting
config.status: creating include/sane/config.h
-> Variables used for compilation/linking:
CPPFLAGS=" -DPATH_SANE_CONFIG_DIR=$(configdir) -DPATH_SANE_DATA_DIR=$(datadir) -DPATH_SANE_LOCK_DIR=$(locksanedir) -DV_MAJOR=1 -DV_MINOR=0"
CFLAGS="-O2 -march=athlon-xp -fomit-frame-pointer -W -Wall"
LDFLAGS=""
LIBS="-lm -ljpeg -ltiff -lieee1284"
-> Installation directories:
Configuration: /etc
Libraries: /usr/lib
Binaries: /usr/bin and /usr/sbin
Manpages: /usr/share/man
Documentation: /usr/doc/sane-1.0.18
Lockfiles: /var/lib/lock/sane
-> Network parameters:
Build saned: yes
IPv6 support: no
-> The following backends will be built:
abaton agfafocus apple artec as6e avision bh brother canon canon630u coolscan coolscan2 dc25 dmc epson fujitsu genesys gt68xx hp leo lexmark matsushita microtek microtek2 mustek mustek_usb nec pie pixma plustek plustek_pp ricoh s9036 sceptre sharp sp15c st400 tamarack test teco1 teco2 teco3 umax umax_pp umax1220u artec_eplus48u ma1509 ibm hp5400 u12 snapscan niash sm3840 hp4200 sm3600 hp3500 stv680 dc210 dc240 canon_pp hpsj5s mustek_pp dell1600n_net v4l net
*** Warning: sane-backends will be built without libusb support. There may
*** be valid reasons to do so, e.g. if you don't use USB scanners or on
*** platforms without libusb support but generally this means that you
*** can't use USB devices with SANE. The most probable cause is that
*** libusb is not installed at all or is too old. See README.
****************************************************************
* Please be sure to read file PROBLEMS in this directory *
* BEFORE running any of the SANE applications. Some devices *
* may be damaged by inproper operation, so please do heed this *
* advice. *
****************************************************************


#uname -a
Linux goodyhome 2.6.22-gentoo-r5 #2 SMP Thu Sep 13 08:59:32 EEST 2007 i686 AMD Athlon(tm) 64 X2 Dual Core Processor 4400+ AuthenticAMD GNU/Linux



Also here is a file
sane-backends-1.0.18/lib/getenv.c


#include "../include/sane/config.h"

#ifndef HAVE_GETENV

char *
getenv(const char *name)
{
char *retval = 0;
#ifdef HAVE_OS2_H
if (0 != DosScanEnv (buf, &retval))
retval = 0;
#else
# error "Missing getenv() on this platform. Please implement."
#endif
return retval;
}

#endif /* !HAVE_GETENV */



Last edited by webdevel; 09-30-2007 at 07:22 AM.
 
  


Reply

Tags
compilation


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
USB Brother MFC 420CN Scanner - sane/scanimage/error i/o issues NosLycn Linux - Hardware 11 11-14-2009 10:58 PM
Sane error message? gymnart Linux - Software 0 08-24-2006 01:04 PM
sane-backends, xef, libexif and the desire for a sedative Paul_Lee Linux - Software 1 04-05-2005 01:55 AM
piping between backends robhargreaves Programming 1 05-01-2004 07:01 AM
Too much backends ? Sane that is ehdwuld Linux - Software 4 09-20-2003 04:28 AM


All times are GMT -5. The time now is 10:17 AM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration