9fans / plan9port

Plan 9 from User Space
https://9fans.github.io/plan9port/
Other
1.61k stars 319 forks source link

m1 darwin issues #603

Closed sfyatee closed 1 year ago

sfyatee commented 1 year ago

I am not sure if it was a recent macOS update that broke plan9port, but now I get this message:

bin/acme: exec devdraw: No such file or directory
acme: can't open display: muxrpc: unexpected eof

If I recall correctly it was working well a few months ago. I'm not sure when was the last time I tried plan9port.

rastagraffix commented 1 year ago

Demian Garcia writes:

bin/acme: exec devdraw: No such file or directory acme: can't open display: muxrpc: unexpected eof

A bit more info about your setup would help. How recent is your plan9port build? What version of MacOS? Hardware model?

I just did a pull and rebuilt and it's working fine for me.

Darwin hqmac49.local 22.3.0 Darwin Kernel Version 22.3.0: Mon Jan 30 20:38:37 PST 2023; root:xnu-8792.81.3~2/RELEASE_ARM64_T6000 arm64 2021 MacBook Pro w/M1 Pro CPU

--lyndon

sfyatee commented 1 year ago
  System Version: macOS 13.2.1 (22D68)
  Kernel Version: Darwin 22.3.0
  Boot Volume: Macintosh HD
  Boot Mode: Normal
  Chip: Apple M1 Pro
  Total Number of Cores: 8 (6 performance and 2 efficiency)
  Memory: 16 GB
  System Firmware Version: 8419.80.7
  OS Loader Version: 8419.80.7
sfyatee commented 1 year ago
  System Version: macOS 13.2.1 (22D68)
  Kernel Version: Darwin 22.3.0
  Boot Volume: Macintosh HD
  Boot Mode: Normal
  Chip: Apple M1 Pro
  Total Number of Cores: 8 (6 performance and 2 efficiency)
  Memory: 16 GB
  System Firmware Version: 8419.80.7
  OS Loader Version: 8419.80.7

The non-GUI elements build fine, only when I try to launch gui-plan9 applications is when it begins to fail on me. I'm not sure where to start looking, either something is corrupted on my system of I'm missing a piece of software. The plan9port I try to build is the most recent one here on Github.

xelxebar commented 1 year ago

FWIW, I'm seeing the same issue when trying to package for Guix (similar to Nix). Building e2a141ae. I suspect it's just a local issue, however, since building much older commits results in the same error.

If you're willing to run Guix, then the following should be reproduction steps:

  1. Copy the following package definition locally:
plan9.scm ```scheme ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2023 B. Wilson ;;; ;;; This file is part of GNU Guix. ;;; ;;; GNU Guix is free software; you can redistribute it and/or modify it ;;; under the terms of the GNU General Public License as published by ;;; the Free Software Foundation; either version 3 of the License, or (at ;;; your option) any later version. ;;; ;;; GNU Guix is distributed in the hope that it will be useful, but ;;; WITHOUT ANY WARRANTY; without even the implied warranty of ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;;; GNU General Public License for more details. ;;; ;;; You should have received a copy of the GNU General Public License ;;; along with GNU Guix. If not, see . (define-module (gnu packages plan9) #:use-module (gnu packages base) #:use-module (gnu packages fontutils) #:use-module (gnu packages gawk) #:use-module (gnu packages perl) #:use-module (gnu packages xorg) #:use-module (guix build-system gnu) #:use-module (guix packages) #:use-module (guix git-download) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix utils)) (define license:lpl1.02 ;; SPDX: LPL-1.02 ((@@ (guix licenses) license) "LPL 1.02" "https://directory.fsf.org/wiki/License:LPL-1.02" "https://www.gnu.org/licenses/license-list.html#lucent102")) (define-public plan9port (let ((commit "e2a141ae0952c2d28a9f500bb9da6dc72e57be3c") (revision "1")) (package (name "plan9port") (version (git-version "1" revision commit)) (source (origin (method git-fetch) (uri (git-reference (url "https://github.com/9fans/plan9port.git") (commit commit))) (file-name (git-file-name name version)) (sha256 (base32 "1pl2b1f4j6zrrilmvx57nwk06hx3rf0sr41drcppqdai1g4c8f3m")))) (build-system gnu-build-system) (inputs (list fontconfig freetype libx11 libxext libxt xorgproto)) (native-inputs (list perl which)) (arguments `(#:phases (modify-phases %standard-phases (delete 'patch-source-shebangs) (replace 'configure (lambda _ (with-output-to-file "LOCAL.config" (lambda _ (display (string-append "CC9=" ,(cc-for-target) "\n")) (display "FONTSRV=fontsrv\n"))))) (replace 'build (lambda _ (invoke "./INSTALL" "-b"))) (delete 'check) (replace 'install (lambda* (#:key outputs #:allow-other-keys) (let* ((out (assoc-ref outputs "out")) (plan9 (string-append out "/lib/9port")) (bin (string-append out "/bin"))) (setenv "PLAN9_TARGET" plan9) (invoke "./INSTALL") (mkdir-p plan9) (copy-recursively (getcwd) plan9) (mkdir-p bin) (link (string-append plan9 "/bin/9") (string-append bin "/9")))))))) (home-page "https://tools.suckless.org/9base/") (synopsis "Plan 9 from User Space") (description "Plan 9 from User Space is a port of various Plan 9 libraries and programs to Unix. Of particular note are the sam(1) and acme(1) editors.") (license (list license:expat license:lpl1.02))))) plan9port ```
  1. Build and run

    $ "$(guix build --file=plan9.scm plan9port)/bin/9" acme
xelxebar commented 1 year ago

@9arcia Why did you close this issue? If you discovered the underlying cause, please share.

sfyatee commented 1 year ago

@xelxebar apologies I forgot to follow up. it was simple user error. I simply had to put it in my path correctly. I am using the fish shell, and was unfamiliar on how it was done correctly.

xelxebar commented 1 year ago

@9arcia Thanks. Hrm. Arguably, sam and acme shouldn't be relying on PATH and instead look directly under 9PATH/bin. Maybe this is a path fixup issue during the install process?