Package: gopher Version: 3.0.11 Severity: important Tags: patch Hi,
your package failed to autobuild: Automatic build of gopher_3.0.11 on beethoven by sbuild/hurd-i386 69 Build started at 20051207-1916 ****************************************************************************** [...] Checking correctness of source dependencies... Toolchain package versions: libc0.3-dev_2.3.5-6 gcc-4.0_4.0.2-4 g++-4.0_4.0.2-4 binutils_2.16.1-2 libstdc++6-4.0-dev_4.0.2-4 libstdc++6_4.0.2-4 ------------------------------------------------------------------------------ dpkg-source: extracting gopher in gopher-3.0.11 dpkg-source: unpacking gopher_3.0.11.tar.gz dpkg-buildpackage: source package is gopher dpkg-buildpackage: source version is 3.0.11 dpkg-buildpackage: host architecture hurd-i386 [...] gcc -g -O2 -Wall -I.. -I.. -I../object -DNOBANNER -DCTRLCPROMPTS -DCONTROLX -DGOPHERLIB=\"//etc/gopher\" -DGOPHERHELP=\"//etc/gopher/gopher.hlp\" -DGLOBALRC=\"//etc/gopher/gopher.rc\" -DREMOTERC=\"//etc/gopher/gopherremote.rc\" -c download.c download.c: In function 'Download_file': download.c:202: error: 'MAXPATHLEN' undeclared (first use in this function) download.c:202: error: (Each undeclared identifier is reported only once download.c:202: error: for each function it appears in.) download.c:235: warning: null argument where non-null required (argument 2) download.c:235: warning: null argument where non-null required (argument 2) download.c:237: warning: null argument where non-null required (argument 2) download.c:237: warning: null argument where non-null required (argument 2) download.c: In function 'BuiltinDownload': download.c:368: error: 'MAXPATHLEN' undeclared (first use in this function) make[2]: *** [download.o] Error 1 make[2]: Leaving directory `/build/buildd/gopher-3.0.11/gopher' make[1]: *** [gopher/gopher] Error 2 make[1]: Leaving directory `/build/buildd/gopher-3.0.11' make: *** [build-stamp] Error 2 ****************************************************************************** Build finished at 20051207-1919 FAILED [dpkg-buildpackage died] MAXPATHLEN is not defined on the GNU system, as there is no maximum path lenght. The attached patch by Ben Asselstine fixes this. As gopher is a Debian native package, can I assume that you are upstream as well, so no further notification is needed? thanks, Michael
diff -uNrd gopher-3.0.11.orig/gopher/download.c gopher-3.0.11/gopher/download.c --- gopher-3.0.11.orig/gopher/download.c 2006-01-07 14:22:03.000000000 -0500 +++ gopher-3.0.11/gopher/download.c 2006-01-07 14:42:53.000000000 -0500 @@ -198,7 +198,7 @@ int start, end; struct stat buf; -#if defined(HAVE_GETCWD) || !defined(HAVE_GET_CURRENT_DIR_NAME) +#if defined(HAVE_GETCWD) && !defined(HAVE_GET_CURRENT_DIR_NAME) curcwd = (char *) malloc(MAXPATHLEN + 2); if (!curcwd) { CursesErrorMsg("Out of memory."); @@ -255,15 +255,15 @@ } } -#ifdef HAVE_GETCWD - getcwd(curcwd, MAXPATHLEN); -#else #ifdef HAVE_GET_CURRENT_DIR_NAME curcwd = get_current_dir_name(); #else +#ifdef HAVE_GETCWD + getcwd(curcwd, MAXPATHLEN); +#else getwd(curcwd); -#endif /* HAVE_GETCWD */ -#endif +#endif +#endif /* HAVE_GET_CURRENT_DIR_NAME */ #ifdef VMS if (chdir("SYS$SCRATCH")!=0) { @@ -364,7 +364,7 @@ GopherObj *gs; -#if defined(HAVE_GETCWD) || !defined(HAVE_GET_CURRENT_DIR_NAME) +#if defined(HAVE_GETCWD) && !defined(HAVE_GET_CURRENT_DIR_NAME) tmppath = (char*)malloc(MAXPATHLEN * 3 + 2); if ( !tmppath ) { CursesErrorMsg("Cannot allocate memory"); @@ -401,9 +401,6 @@ GSsetPath(gs, names[choice]); -#ifdef HAVE_GETCWD - getcwd(tmppath,MAXPATHLEN); -#else #ifdef HAVE_GET_CURRENT_DIR_NAME tmppath = get_current_dir_name(); if ( sizeof(tmppath) <= (strlen(tmppath) + strlen(names[choice]) + 1) ) @@ -413,6 +410,9 @@ return; } #else +#ifdef HAVE_GETCWD + getcwd(tmppath,MAXPATHLEN); +#else getwd(tmppath); #endif #endif