[MacPorts] #70960: leptonica @1.84.1_1 does not build on PPC Tiger, Mac OS X 10.4.11, because of: utils2.c:3133: error: '_CS_DARWIN_USER_TEMP_DIR' undeclared (first use in this function)

MacPorts noreply at macports.org
Sat Sep 28 07:32:45 UTC 2024


#70960: leptonica @1.84.1_1 does not build on PPC Tiger, Mac OS X 10.4.11, because
of: utils2.c:3133: error: '_CS_DARWIN_USER_TEMP_DIR' undeclared (first use
in this function)
-----------------------+-----------------------
 Reporter:  ballapete  |      Owner:  (none)
     Type:  defect     |     Status:  new
 Priority:  Normal     |  Milestone:
Component:  ports      |    Version:  2.10.1
 Keywords:  tiger ppc  |       Port:  leptonica
-----------------------+-----------------------
 {{{
 /bin/sh ../libtool  --tag=CC   --mode=compile /opt/local/bin/gcc-apple-4.2
 -std=gnu99 -DHAVE_CONFIG_H -I. -I..   -I/opt/local/include/libpng16
 -I/opt/local/include/webp -I/opt/local/include/webp
 -I/opt/local/include/openjpeg-2.5 -I/opt/local/include/giflib5
 -I/opt/local/include  -pipe -I/opt/local/include/giflib5 -Os -arch ppc -MT
 utils2.lo -MD -MP -MF .deps/utils2.Tpo -c -o utils2.lo utils2.c
 libtool: compile:  /opt/local/bin/gcc-apple-4.2 -std=gnu99 -DHAVE_CONFIG_H
 -I. -I.. -I/opt/local/include/libpng16 -I/opt/local/include/webp
 -I/opt/local/include/webp -I/opt/local/include/openjpeg-2.5
 -I/opt/local/include/giflib5 -I/opt/local/include -pipe
 -I/opt/local/include/giflib5 -Os -arch ppc -MT utils2.lo -MD -MP -MF
 .deps/utils2.Tpo -c utils2.c  -fno-common -DPIC -o .libs/utils2.o
 utils2.c: In function 'genPathname':
 utils2.c:3133: error: '_CS_DARWIN_USER_TEMP_DIR' undeclared (first use in
 this function)
 utils2.c:3133: error: (Each undeclared identifier is reported only once
 utils2.c:3133: error: for each function it appears in.)
 make[2]: *** [utils2.lo] Error 1
 make[2]: Leaving directory
 `/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_graphics_leptonica/leptonica/work/leptonica-1.84.1/src'
 }}}

 This is the corresponding code, which might work in `macOS` (here it's
 `Mac OS X`):

 {{{
  3131       } else {  /* Rewrite with "/tmp" specified for the directory.
 */
  3132   #if defined(__APPLE__)
  3133           size_t n = confstr(_CS_DARWIN_USER_TEMP_DIR, pathout,
 size);
  3134           if (n == 0 || n > size) {
  3135               /* Fall back to using /tmp */
  3136               stringCopy(pathout, cdir, dirlen);
  3137           } else {
  3138               /* Add the rest of cdir */
  3139               if (dirlen > 4)
  3140                   stringCat(pathout, size, cdir + 4);
  3141           }
 }}}

-- 
Ticket URL: <https://trac.macports.org/ticket/70960>
MacPorts <https://www.macports.org/>
Ports system for macOS


More information about the macports-tickets mailing list