Opened 19 months ago

Last modified 19 months ago

#67343 new defect

libxkbcommon-x11 @1.5.0 does not build on PPC Tiger, Mac OS X 10.4.11, because of fatal error: spawn.h: No such file or directory

Reported by: ballapete (Peter "Pete" Dyballa) Owned by:
Priority: Normal Milestone:
Component: ports Version: 2.8.1
Keywords: tiger ppc Cc: ryandesign@…
Port: libxkbcommon-x11

Description

[175/194] /opt/local/bin/gcc-mp-7 -Itest-x11comp.p -I. -I../libxkbcommon-1.5.0 -I../libxkbcommon-1.5.0/src -I../libxkbcommon-1.5.0/include -I/opt/local/include/LegacySupport -I/opt/local/include -fdiagnostics-color=always -Wall -Winvalid-pch -Wextra -std=c11 -g -fno-strict-aliasing -Wno-unused-parameter -Wno-missing-field-initializers -Wpointer-arith -Wmissing-declarations -Wformat=2 -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wbad-function-cast -Wshadow -Wlogical-op -Wdate-time -Wwrite-strings -pipe -Os -arch ppc -MD -MQ test-x11comp.p/test_x11comp.c.o -MF test-x11comp.p/test_x11comp.c.o.d -o test-x11comp.p/test_x11comp.c.o -c ../libxkbcommon-1.5.0/test/x11comp.c
FAILED: test-x11comp.p/test_x11comp.c.o 
/opt/local/bin/gcc-mp-7 -Itest-x11comp.p -I. -I../libxkbcommon-1.5.0 -I../libxkbcommon-1.5.0/src -I../libxkbcommon-1.5.0/include -I/opt/local/include/LegacySupport -I/opt/local/include -fdiagnostics-color=always -Wall -Winvalid-pch -Wextra -std=c11 -g -fno-strict-aliasing -Wno-unused-parameter -Wno-missing-field-initializers -Wpointer-arith -Wmissing-declarations -Wformat=2 -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wbad-function-cast -Wshadow -Wlogical-op -Wdate-time -Wwrite-strings -pipe -Os -arch ppc -MD -MQ test-x11comp.p/test_x11comp.c.o -MF test-x11comp.p/test_x11comp.c.o.d -o test-x11comp.p/test_x11comp.c.o -c ../libxkbcommon-1.5.0/test/x11comp.c
../libxkbcommon-1.5.0/test/x11comp.c:27:10: fatal error: spawn.h: No such file or directory
 #include <spawn.h>
          ^~~~~~~~~
compilation terminated.
ninja: build stopped: subcommand failed.
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_devel_libxkbcommon/libxkbcommon-x11/work/build" && /opt/local/bin/ninja -j1 -v

The missing file does exist:

-rw-r--r-- 1 root     admin 1324 30. Apr 01:09 /opt/local/include/LegacySupport/sys/spawn.h
-rw-r--r-- 1 macports admin 1324 27. Mär 10:47 /opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_devel_legacy-support/legacy-support/work/macports-legacy-support-1.0.9/include/sys/spawn.h

but in sys subdirectory!

Attachments (2)

main.log (138.1 KB) - added by ballapete (Peter "Pete" Dyballa) 19 months ago.
Main.log from PPC Tiger, Mac OS X 10.4.11
patch-spawn.h-test_x11comp.c.diff (279 bytes) - added by ballapete (Peter "Pete" Dyballa) 19 months ago.
Patch to correct path to spawn.h

Download all attachments as: .zip

Change History (6)

Changed 19 months ago by ballapete (Peter "Pete" Dyballa)

Attachment: main.log added

Main.log from PPC Tiger, Mac OS X 10.4.11

Changed 19 months ago by ballapete (Peter "Pete" Dyballa)

Patch to correct path to spawn.h

comment:1 Changed 19 months ago by ballapete (Peter "Pete" Dyballa)

The patch corrects the problem with the path to spawn.h, but the next failure becomes visible:

[175/194] /opt/local/bin/gcc-mp-7 -Itest-x11comp.p -I. -I../libxkbcommon-1.5.0 -I../libxkbcommon-1.5.0/src -I../libxkbcommon-1.5.0/include -I/opt/local/include/LegacySupport -I/opt/local/include -fdiagnostics-color=always -Wall -Winvalid-pch -Wextra -std=c11 -g -fno-strict-aliasing -Wno-unused-parameter -Wno-missing-field-initializers -Wpointer-arith -Wmissing-declarations -Wformat=2 -Wstrict-prototypes -Wmissing-prototypes -Wnested-externs -Wbad-function-cast -Wshadow -Wlogical-op -Wdate-time -Wwrite-strings -pipe -Os -arch ppc -MD -MQ test-x11comp.p/test_x11comp.c.o -MF test-x11comp.p/test_x11comp.c.o.d -o test-x11comp.p/test_x11comp.c.o -c ../libxkbcommon-1.5.0/test/x11comp.c
../libxkbcommon-1.5.0/test/x11comp.c: In function 'main':
../libxkbcommon-1.5.0/test/x11comp.c:89:15: warning: implicit declaration of function 'posix_spawnp'; did you mean 'posix_openpt'? [-Wimplicit-function-declaration]
         ret = posix_spawnp(&xvfb_pid, "Xvfb", NULL, NULL, xvfb_argv, envp);
               ^~~~~~~~~~~~
               posix_openpt
../libxkbcommon-1.5.0/test/x11comp.c:89:15: warning: nested extern declaration of 'posix_spawnp' [-Wnested-externs]
[176/194] /opt/local/bin/gcc-mp-7  -o test-x11comp test-x11comp.p/test_x11comp.c.o -L/opt/local/lib -I/opt/local/include/LegacySupport -I/opt/local/include -Wl,-dead_strip_dylibs -Wl,-headerpad_max_install_names -Wl,-undefined,error -Wl,-headerpad_max_install_names -lMacportsLegacySupport -arch ppc -pipe -Os -arch ppc libxkbcommon-x11-internal.a libxkbcommon-test-internal.a /opt/local/lib/libxcb.dylib /opt/local/lib/libxcb-xkb.dylib
FAILED: test-x11comp 
/opt/local/bin/gcc-mp-7  -o test-x11comp test-x11comp.p/test_x11comp.c.o -L/opt/local/lib -I/opt/local/include/LegacySupport -I/opt/local/include -Wl,-dead_strip_dylibs -Wl,-headerpad_max_install_names -Wl,-undefined,error -Wl,-headerpad_max_install_names -lMacportsLegacySupport -arch ppc -pipe -Os -arch ppc libxkbcommon-x11-internal.a libxkbcommon-test-internal.a /opt/local/lib/libxcb.dylib /opt/local/lib/libxcb-xkb.dylib
Undefined symbols:
  "_posix_spawnp", referenced from:
      _main in test_x11comp.c.o
      _main in test_x11comp.c.o
ld: symbol(s) not found
collect2: error: ld returned 1 exit status
ninja: build stopped: subcommand failed.
Command failed:  cd "/opt/local/var/macports/build/_opt_local_var_macports_sources_nue.de.rsync.macports.org_macports_release_tarballs_ports_devel_libxkbcommon/libxkbcommon-x11/work/build" && /opt/local/bin/ninja -j1 -v 

The library function posix_spawnp() is not provided by Legacy Support

comment:2 Changed 19 months ago by kencu (Ken)

I was working on a posix_spawn implementation for Tiger a couple of years ago, but I never fully finished it. I can upload what I have.

In the meantime, perhaps you can look at the change that brought this in, and see if you can come up with an #ifdef setup that will provide something similar in this port for Tiger to use.

comment:3 Changed 19 months ago by ballapete (Peter "Pete" Dyballa)

Maybe two problems: there was no previous version installed with port and libxkbcommon-1.4.1/test/x11comp.c and libxkbcommon-1.5.0/test/x11comp.c look quite similar:

 -rw-rw-r--     ran/ran        5550 May 21 21:55 2022 libxkbcommon-1.4.1/test/x11comp.c   |  -rw-rw-r--     ran/ran        5550 Jan  2 20:23 2023 libxkbcommon-1.5.0/test/x11comp.c

I'll see if I can find an earlier version. OTOH, is it necessary to compile the test files? If some X client will fail in the future we would have a suspicion at once…

comment:4 Changed 19 months ago by ballapete (Peter "Pete" Dyballa)

The file has Copyright © 2014 Ran Benita <ran234@gmail.com> and did not change since released in version 1.0.

Note: See TracTickets for help on using tickets.