From 59f200519c09a072ad32afe6589a298f06d5573c Mon Sep 17 00:00:00 2001 From: Marcus Kammer Date: Sun, 5 Nov 2023 19:54:16 +0100 Subject: [PATCH] Add shell script to build emacs 29 --- sbcl-nginx.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/sbcl-nginx.yml b/sbcl-nginx.yml index 55f2847..841f1bb 100644 --- a/sbcl-nginx.yml +++ b/sbcl-nginx.yml @@ -470,6 +470,40 @@ write_files: curl https://git.sr.ht/~marcuskammer/cloudinit/blob/main/.sbclrc -o /home/cl/.sbclrc && chown cl:cl /home/cl/.sbclrc sbcl --non-interactive --eval "(ql:quickload '(:hunchentoot :jonathan :spinneret :dexador :rove :vecto :woo :clsql-sqlite3 :mito :bknr.datastore :cl-project))" --quit + - path: /home/cl/build_emacs.sh + owner: cl:cl + persmissions: '0755' + defer: True + content: | + #!/bin/bash + + # Update package list and install dependencies + sudo apt update + sudo apt install -y autoconf texinfo libncurses-dev libgnutls28-dev libjansson-dev libgccjit-11-dev + + # Clone the Emacs repository + git clone git://git.sv.gnu.org/emacs.git + cd emacs + + # Check out the Emacs-29 branch (replace 'emacs-29' with the specific version if different) + git checkout emacs-29 + + # Prepare for build + ./autogen.sh + + # Configure Emacs for building without X11, without GTK, without image support, and with native compilation + ./configure --without-x --without-imagemagick --without-jpeg --without-png --without-gif --without-tiff --without-xpm --with-modules --with-nativecomp + + # Build Emacs + make -j$(nproc) + + # If the build succeeds, install Emacs + sudo make install + + # Optionally, clean up the build directory + cd .. + rm -rf emacs + runcmd: # Run Certbot to obtain SSL certificates and configure Nginx - certbot certonly --nginx -d u1.metalisp.dev --non-interactive --agree-tos --email marcus.kammer@mailbox.org --redirect