├── .gitignore
├── LICENSE
├── README.org
├── bemacs-requirements.sh
├── build-emacs.sh
├── config-options.txt
├── materials
├── emacs-big-sur.icns
├── emacs-git-version.el
└── info.plist
└── patches
├── fix-window-role.patch
├── libgccjit-patch.patch
├── lion-fullscreen.patch
├── no-frame-refocus-cocoa.patch
├── show-git-sha1-in-version.patch
└── system-appearance.patch
/.gitignore:
--------------------------------------------------------------------------------
1 | *.DS_STORE
2 | /emacs-git/
3 | /build-logs/
4 |
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2021 mclear-tools
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
22 |
--------------------------------------------------------------------------------
/README.org:
--------------------------------------------------------------------------------
1 | #+html:
2 |
3 | Here you'll find a shell script for building emacs on macos, along with a few
4 | other useful bits.
5 |
6 | There is, of course, the great [[https://emacsformacosx.com][Emacs for macos]]. This is probably the most
7 | straightforward way to get emacs for the mac. There is also [[https://brew.sh][homebrew]] and the
8 | various ways of building emacs for that. Three great ones are:
9 |
10 | - https://github.com/d12frosted/homebrew-emacs-plus
11 | - https://github.com/daviderestivo/homebrew-emacs-head
12 | - https://github.com/railwaycat/homebrew-emacsmacport
13 |
14 | There are also a few great sources for looking at how to build emacs on macos. See
15 | for example:
16 |
17 | - https://github.com/jimeh/build-emacs-for-macos
18 | - https://github.com/renard/emacs-build-macosx
19 |
20 |
21 | So why another build script? Well, in keeping with the way I use emacs, I
22 | wanted to be able to build it in the way that I preferred, using all the
23 | options that I thought important. Plus I also wanted to understand more about
24 | the build process. Since I'm not a programmer, I tried to write a [[https://en.wikipedia.org/wiki/Shell_script][shell script]]
25 | that would be as accessible to other non-programmers as possible. It was this
26 | latter that I found particularly lacking in my search on the internet for
27 | instructions about how to build emacs using any but the most basic of
28 | settings. So below you'll find a discussion of the various contents of this
29 | repo, what they do (to the best of my very limited knowledge) and why they are
30 | there. Hopefully this will be of help to those people who, like myself, want
31 | more control over how emacs works but lack much of the programming knowledge
32 | that is assumed for building it.
33 |
34 | *Note* that this build process currently works well for me using a 2021 M1 Macbook
35 | Pro with Monterey 12.0.1. It should build either the latest emacs release, emacs
36 | 28, or the master branch just fine. I have not tested this on other machines or
37 | for other kinds of build. Builds are specific to the machine on which they are
38 | created, and not guaranteed to work without breakage on other machines (no
39 | dylibs are included though see [[https://imrehorvath.wordpress.com/2021/04/17/wanna-build-gnu-emacs-on-macos-from-source/][here]] if you want something more self-contained).
40 |
41 | ** Emacs & Git
42 | The first thing one needs to do in building emacs from the source files is
43 | clone the emacs git repository. You can do this either by cloning from the
44 | main repo: =git clone https://git.savannah.gnu.org/git/emacs.git= or from
45 | the github mirror: =git clone https://github.com/emacs-mirror/emacs.git=. It
46 | doesn't really matter which one you choose. Clone it to somewhere
47 | convenient on your system (I clone it to a subdirectory of this
48 | =build-emacs= dir).
49 |
50 | ** Build Requirements
51 | You'll need to install the following to build emacs. For convenience, you
52 | can use the install script that I've provided in the repo. From the
53 | emacs-build directory run =chmod u+x bemacs-requirements.sh= and then
54 | =./bemacs-requirements.sh= and you should be all set.
55 |
56 | - Xcode command line tools
57 | - [[https://brew.sh][Homebrew]]
58 | - autoconf
59 | - automake
60 | - jpeg
61 | - gnutls
62 | - texinfo
63 | - gcc
64 | - libgccjit
65 | - pkg-config
66 | - jansson
67 |
68 |
69 | ** Config Options
70 |
71 | [[file:config-options.txt][Config-options.txt]] lists the various options one can use to build emacs.
72 | It is generated by running =./autogen.sh= in the emacs git repo. There are many
73 | to choose from, though slightly [[https://github.com/renard/emacs-build-macosx#configuration-report][less so on macos]].
74 |
75 | The options I use to build emacs currently are:
76 |
77 | #+begin_src bash
78 | ./configure \
79 | --with-ns \
80 | --with-native-compilation \
81 | --with-xwidgets \
82 | --with-mailutils \
83 | --with-json \
84 | --with-modules \
85 | --without-compress-install \ # don't compress things like help & info files
86 | --with-dbus \ # this is mostly useless on mac but harmless to include
87 | --program-transform-name='s/^ctags$/emctags/' \ # avoid ctags namespace conflict
88 | #+end_src
89 |
90 | Depending on what version you're building you might also want to add =--with-treesitter= or other options new with emacs 29. For info consult [[https://github.com/emacs-mirror/emacs/blob/master/etc/NEWS.29][Emacs 29 News.]]
91 |
92 | ** Patches
93 |
94 | These patches are various modifications applied to emacs during the build
95 | process. You can read more about the =patch= command by running =man patch= on the
96 | command line or looking at some of the examples[[https://www.thegeekstuff.com/2014/12/patch-command-examples/][ here]]. Currently the build script
97 | uses all patches. If you don't want to use one of the patches below, remove it
98 | from the =patches= directory or modify the build script (e.g by applying the
99 | patches individually rather than as part of a =for= loop). Here are the patches
100 | currently included:
101 |
102 | - Emacs git version: allows for showing git sha1 version of the built emacs in
103 | =emacs-version= command
104 | - Lion fullscreen: allow native fullscreen (especially useful for the new
105 | "notched" macbooks)
106 | - No window refocus: better treatment of window focus transfer
107 | - System appearance: allows for automatic theme switching with macos theme
108 | change; for an example of how to set it up see the [[file:patches/system-appearance.patch][patch]] or see the
109 | description [[https://github.com/d12frosted/homebrew-emacs-plus#system-appearance-change][here]]
110 | - Windowing: better treatment with window managers; see [[https://github.com/d12frosted/homebrew-emacs-plus/issues/157][here]] for further discussion
111 |
112 | ** Build-emacs.sh
113 |
114 | Please note that large portions of the build script are derived from, or
115 | inspired by:
116 |
117 | - https://github.com/renard/emacs-build-macosx (general structure)
118 | - https://github.com/d12frosted/homebrew-emacs-plus (patches)
119 | - https://github.com/jimeh/build-emacs-for-macos (instructions on build and config)
120 |
121 | By default the build script builds off of the master branch but you can
122 | also specify the version you want to build from any commit within recent
123 | Emacs history (i.e. Emacs >= 24).
124 |
125 | To *use* the build script simply:
126 |
127 | 1. Clone this repo.
128 | 2. Make sure that you have cloned the emacs source (e.g. =git clone https://github.com/emacs-mirror/emacs.git=).
129 | 3. Get all requirements for build (=chmod u+x ./bemacs-requirements.sh= and =./bemacs-requirements.sh=)
130 | 4. Set the variables in the build script appropriately. Note that the Emacs source repo is set by default as being in the =~/Documents= directory.
131 | 5. Make the script executable using =chmod u+x build-emacs.sh= and have the
132 | script in your path.
133 | 6. Run =./build-emacs.sh= (if you don't want to build from HEAD of the master
134 | branch you also need to include either the git sha1 or source/branch from
135 | which you are building)
136 | 7. Add emacs and emacsclient to your =PATH= by adding the following to your =.zshrc=
137 | or =.zprofile= (assuming you use zsh):
138 |
139 | #+begin_src sh
140 | export PATH=$PATH:/Applications/Emacs.app/Contents/MacOS
141 | export PATH=$PATH:/Applications/Emacs.app/Contents/MacOS/bin
142 | #+end_src
143 |
144 | If you're wondering whether the most recent commit on =master= is stable, you
145 | might check out [[https://github.com/jimeh/emacs-builds/issues/7][jimeh's]] "good-version" list of emacs-main versions to see which
146 | git sha points to a stable commit.
147 |
148 | ** Build-logs
149 |
150 | Each build with =build-emacs.sh= generates a subdirectory in =build-logs= with
151 | a set of build logs organized by name, date, and commit.
152 |
153 | ** Materials
154 |
155 | I've included a big-sur icon by memeplex (from [[https://github.com/d12frosted/homebrew-emacs-plus/issues/419][here]]). There is an info.plist
156 | to transfer to the emacs build along with it. There is also an elisp file into
157 | which the emacs build git sha1 will be inscribed and the file copied to the
158 | emacs build's site-lisp (see the =SITELISP= variable in =build-emacs.sh=).
159 |
--------------------------------------------------------------------------------
/bemacs-requirements.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | # Install build requirements for emacs
4 | # Ask for the administrator password upfront.
5 | sudo -v
6 |
7 | # Keep-alive: update existing `sudo` time stamp until the script has finished.
8 | while true; do sudo -n true; sleep 60; kill -0 "$$" || exit; done 2>/dev/null &
9 |
10 | # Install xcode command line tools
11 | xcode-select --install
12 |
13 | # Check for Homebrew,
14 | # Install if we don't have it
15 | if ! command -v brew &1
16 | then
17 | echo "Installing homebrew..."
18 | /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
19 | else
20 | echo "Homebrew already installed!"
21 | fi
22 |
23 | # Update homebrew recipes
24 | brew update
25 |
26 | # Upgrade any already-installed formulae.
27 | brew upgrade
28 |
29 | binaries=(
30 | autoconf
31 | automake
32 | gcc
33 | git
34 | giflib
35 | gnutls
36 | jansson
37 | jpeg
38 | libgccjit
39 | libtiff
40 | libxml2
41 | pkg-config
42 | texinfo
43 | )
44 |
45 | echo "installing binaries..."
46 | brew install ${binaries[@]}
47 |
48 | echo "build requirements installed"
49 |
--------------------------------------------------------------------------------
/build-emacs.sh:
--------------------------------------------------------------------------------
1 | #!/bin/sh
2 |
3 | ## Derived from https://github.com/renard/emacs-build-macosx
4 | ## Patches from https://github.com/d12frosted/homebrew-emacs-plus
5 | ## See also https://github.com/jimeh/build-emacs-for-macos
6 |
7 | # ======================================================
8 | # Uncomment `set -e' if you want script to exit
9 | # on non-zero status
10 | # See https://www.gnu.org/software/bash/manual/html_node/The-Set-Builtin.html
11 | # ======================================================
12 |
13 | # set -e
14 |
15 | # ======================================================
16 | # Set Variables
17 | # ======================================================
18 |
19 | ROOT_DIR="`pwd`"
20 | BUILD_DIR=/tmp/emacs-build
21 | SRC_DIR=$HOME/Documents/emacs/
22 | GIT_VERSION=emacs-git-version.el
23 | SITELISP=/Applications/Emacs.app/Contents/Resources/site-lisp
24 | BREW=$(brew --prefix)
25 |
26 | echo "
27 | # ======================================================
28 | # Use Homebrew libxml & image libraries
29 | # ======================================================
30 | "
31 |
32 | # Check for Homebrew,
33 | if ! command -v brew &1
34 | then
35 | echo "Please install homebrew -- see bemacs-requirements.sh"
36 | else
37 | echo "Homebrew installed!"
38 | fi
39 |
40 | export LDFLAGS="-L${BREW}/opt/libxml2/lib -L${BREW}/opt/giflib/lib -L${BREW}/opt/webp/lib -L${BREW}/opt/jpeg/lib -L${BREW}/opt/libtiff/lib"
41 |
42 | export CPPFLAGS="-I${BREW}/opt/libxml2/include -I${BREW}/opt/jpeg/include -I${BREW}/opt/libtiff/include -I${BREW}/opt/giflib/include"
43 |
44 | echo "
45 | # ======================================================
46 | # Use Homebrew libxml pkgconfig
47 | # ======================================================
48 | "
49 |
50 | export PKG_CONFIG_PATH="${BREW}/opt/libxml2/lib/pkgconfig"
51 |
52 | echo "
53 | # ======================================================
54 | # Start with a clean build
55 | # ======================================================
56 | "
57 |
58 | rm -rf ${BUILD_DIR}
59 | mkdir ${BUILD_DIR}
60 |
61 | cd ${SRC_DIR}
62 |
63 | # ======================================================
64 | # Input for version otherwise default to master
65 | # ======================================================
66 |
67 | if test -n "$1"; then
68 | commit="$1"
69 | else
70 | commit="origin/master"
71 | git checkout master
72 | git pull
73 | fi
74 |
75 | git archive --format tar $commit | tar -C ${BUILD_DIR} -xvf -
76 |
77 | # ======================================================
78 | # Set variables for git, time, & patches
79 | # ======================================================
80 |
81 | REV=`git log -n 1 --no-color --pretty='format:%h' ${commit}`
82 | TIMESTAMP=`git log -n 1 --no-color --pretty='format:%at' ${commit}`
83 | PATCH_LIST=`find ${ROOT_DIR}/patches/ -name '*.patch'`
84 | cd ${BUILD_DIR}
85 |
86 | echo "
87 | # ======================================================
88 | # Apply Patches
89 | # ======================================================
90 | "
91 |
92 | # Note that this applies all patches in 'patches' dir
93 | for f in ${PATCH_LIST}; do
94 | echo "Applying patch `basename $f`"
95 | patch -p1 -i $f
96 | done
97 |
98 | # ======================================================
99 | # Info settings
100 | # ======================================================
101 |
102 | # Here we set infofiles and variables for versioning
103 |
104 | STRINGS="
105 | nextstep/templates/Emacs.desktop.in
106 | nextstep/templates/Info-gnustep.plist.in
107 | nextstep/templates/Info.plist.in
108 | nextstep/templates/InfoPlist.strings.in"
109 |
110 | DAY=`date -u -r $TIMESTAMP +"%Y-%m-%d_%H-%M-%S"`
111 | ORIG=`grep ^AC_INIT configure.ac`
112 | VNUM=`echo $ORIG | sed 's#^AC_INIT(\(.*\))#\1#; s/ //g' | cut -f2 -d,`
113 | VERS="$DAY Git $REV"
114 | DESCR="Emacs_Cocoa_${VNUM}_${DAY}_Git_${REV}"
115 |
116 | echo "
117 | # ======================================================
118 | # Autogen/copy_autogen
119 | # ======================================================
120 | "
121 |
122 | # Generate config files
123 | ./autogen.sh
124 |
125 | # ======================================================
126 | # Set Compile Flags
127 | # ======================================================
128 |
129 | # Use Clang for slightly faster builds
130 | # See https://leeifrankjaw.github.io/articles/clang_vs_gcc_for_emacs.html
131 | # See https://alibabatech.medium.com/gcc-vs-clang-llvm-an-in-depth-comparison-of-c-c-compilers-899ede2be378
132 | # See https://docs.oracle.com/cd/E19957-01/806-3567/cc_options.html for CFLAG option explanations
133 | CFLAGS="-g -O2"
134 | export CC=clang
135 | export OBJC=clang
136 |
137 | # ======================================================
138 | # Inscribe Version in Info files
139 | # ======================================================
140 |
141 | for f in $STRINGS; do
142 | sed -e "s/@version@/@version@ $VERS/" -i '' $f
143 | done
144 |
145 | echo "
146 | # ======================================================
147 | # Configure emacs
148 | # ======================================================
149 | "
150 |
151 | # Here we set config options for emacs For more info see config-options.txt.
152 | # Note that this renames ctags in emacs so that it doesn't conflict with other
153 | # installed ctags; see and don't compress info files, etc
154 | # https://www.topbug.net/blog/2016/11/10/installing-emacs-from-source-avoid-the-conflict-of-ctags/
155 | ./configure \
156 | --with-dbus \
157 | --with-ns \
158 | --with-native-compilation \
159 | --with-xwidgets \
160 | --with-modules \
161 | --with-mailutils \
162 | --with-json \
163 | --without-compress-install \
164 | --program-transform-name='s/^ctags$/emctags/' \
165 |
166 | echo "
167 | # ======================================================
168 | # Build and install everything
169 | # ======================================================
170 | "
171 |
172 | ## Check number of processors & use as many as we can!
173 | NCPU=$(getconf _NPROCESSORS_ONLN)
174 |
175 | ## Send output to log file using tee
176 | ## See https://stackoverflow.com/a/60432203/6277148
177 | make bootstrap -j$NCPU | tee bootstrap-log.txt || exit 1 && make install -j$NCPU | tee build-log.txt
178 |
179 | echo "DONE!"
180 |
181 | echo "
182 | # ======================================================
183 | # Delete old app & Move new app
184 | # ======================================================
185 | "
186 |
187 | # Close any emacs sessions
188 | pkill -i emacs
189 |
190 | # Remove old emacs
191 | # See https://stackoverflow.com/a/677212/6277148
192 | # and https://stackoverflow.com/a/638980/6277148
193 | # for discussion of confitional checks for files
194 |
195 | if [ -e /Applications/Emacs.app ]
196 | then
197 | if command -v trash &1
198 | then
199 | echo "Trashing old emacs..."
200 | trash /Applications/Emacs.app
201 | else
202 | echo "Removing old emacs..."
203 | rm -rf /Applications/Emacs.app
204 | fi
205 | fi
206 |
207 | # Move build to applications folder
208 | mv ${BUILD_DIR}/nextstep/Emacs.app /Applications
209 |
210 | echo "DONE!"
211 |
212 | echo "
213 | # ======================================================
214 | # Record Git SHA
215 | # ======================================================
216 | "
217 |
218 | # This records the Git SHA to an elisp file and
219 | # moves it to the site-lisp dir in the emacs build
220 |
221 | cp ${ROOT_DIR}/materials/${GIT_VERSION} ${BUILD_DIR}/
222 | sed -e "s/@@GIT_COMMIT@@/$REV/" -i '' ${BUILD_DIR}/${GIT_VERSION}
223 | mv -f ${BUILD_DIR}/${GIT_VERSION} ${SITELISP}/${GIT_VERSION}
224 |
225 | echo "DONE!"
226 |
227 | echo "
228 | # ======================================================
229 | # Change icon
230 | # ======================================================
231 | "
232 |
233 | # Copy new icon to emacs (currently using a big sur icon)
234 | # See https://github.com/d12frosted/homebrew-emacs-plus/issues/419
235 | cp ${ROOT_DIR}/materials/emacs-big-sur.icns /Applications/Emacs.app/Contents/Resources/Emacs.icns
236 |
237 | echo "DONE!"
238 |
239 | echo "
240 | # ======================================================
241 | # Copy C Source Code
242 | # ======================================================
243 | "
244 |
245 | # Copy C source files to Emacs
246 | cp -r ${SRC_DIR}/src /Applications/Emacs.app/Contents/Resources/
247 |
248 | echo "DONE!"
249 |
250 | echo "
251 | # ======================================================
252 | # Create Log files
253 | # ======================================================
254 | "
255 |
256 | # Make a directory for the build's log files and move them there
257 | # Note that this removes a previous identical dir if making multiple similar builds
258 | rm -rf ${ROOT_DIR}/build-logs/${DESCR}; mkdir ${ROOT_DIR}/build-logs/
259 | mv ${BUILD_DIR}/config.log ${ROOT_DIR}/build-logs/config-${DESCR}.log
260 | mv ${BUILD_DIR}/build-log.txt ${ROOT_DIR}/build-logs/build-log-${DESCR}.txt
261 | mv ${BUILD_DIR}/bootstrap-log.txt ${ROOT_DIR}/build-logs/bootstrap-log-${DESCR}.txt
262 |
263 | echo "DONE!"
264 |
265 | echo "
266 | # ======================================================
267 | # Cleanup
268 | # ======================================================
269 | "
270 |
271 | # Delete build dir
272 | rm -rf ${BUILD_DIR}
273 |
274 | echo "DONE!"
275 |
276 | echo "
277 | # ======================================================
278 | # Add executables to path
279 | #
280 | # Be sure to add /Applications/Emacs.app/Contents/MacOS/bin
281 | # to your .zshrc or .profile path like so:
282 | # export PATH=\$PATH:/Applications/Emacs.app/Contents/MacOS
283 | # export PATH=\$PATH:/Applications/Emacs.app/Contents/MacOS/bin
284 | # ======================================================
285 | "
286 |
287 | export PATH=$PATH:/Applications/Emacs.app/Contents/MacOS
288 | export PATH=$PATH:/Applications/Emacs.app/Contents/MacOS/bin
289 |
290 | echo "execs added to this terminal session -- please
291 | modify your .zshrc or .zprofile file accordingly"
292 |
293 | echo "
294 | # ======================================================
295 | # Open new emacs
296 | # ======================================================
297 | "
298 |
299 | open /Applications/Emacs.app
300 |
301 | echo "Build script finished!"
302 |
--------------------------------------------------------------------------------
/config-options.txt:
--------------------------------------------------------------------------------
1 | `configure' configures GNU Emacs 29.0.50 to adapt to many kinds of systems.
2 |
3 | Usage: ./configure [OPTION]... [VAR=VALUE]...
4 |
5 | To assign environment variables (e.g., CC, CFLAGS...), specify them as
6 | VAR=VALUE. See below for descriptions of some of the useful variables.
7 |
8 | Defaults for the options are specified in brackets.
9 |
10 | Configuration:
11 | -h, --help display this help and exit
12 | --help=short display options specific to this package
13 | --help=recursive display the short help of all the included packages
14 | -V, --version display version information and exit
15 | -q, --quiet, --silent do not print `checking ...' messages
16 | --cache-file=FILE cache test results in FILE [disabled]
17 | -C, --config-cache alias for `--cache-file=config.cache'
18 | -n, --no-create do not create output files
19 | --srcdir=DIR find the sources in DIR [configure dir or `..']
20 |
21 | Installation directories:
22 | --prefix=PREFIX install architecture-independent files in PREFIX
23 | [/usr/local]
24 | --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX
25 | [PREFIX]
26 |
27 | By default, `make install' will install all the files in
28 | `/usr/local/bin', `/usr/local/lib' etc. You can specify
29 | an installation prefix other than `/usr/local' using `--prefix',
30 | for instance `--prefix=$HOME'.
31 |
32 | For better control, use the options below.
33 |
34 | Fine tuning of the installation directories:
35 | --bindir=DIR user executables [EPREFIX/bin]
36 | --sbindir=DIR system admin executables [EPREFIX/sbin]
37 | --libexecdir=DIR program executables [EPREFIX/libexec]
38 | --sysconfdir=DIR read-only single-machine data [PREFIX/etc]
39 | --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com]
40 | --localstatedir=DIR modifiable single-machine data [PREFIX/var]
41 | --runstatedir=DIR modifiable per-process data [LOCALSTATEDIR/run]
42 | --libdir=DIR object code libraries [EPREFIX/lib]
43 | --includedir=DIR C header files [PREFIX/include]
44 | --oldincludedir=DIR C header files for non-gcc [/usr/include]
45 | --datarootdir=DIR read-only arch.-independent data root [PREFIX/share]
46 | --datadir=DIR read-only architecture-independent data [DATAROOTDIR]
47 | --infodir=DIR info documentation [DATAROOTDIR/info]
48 | --localedir=DIR locale-dependent data [DATAROOTDIR/locale]
49 | --mandir=DIR man documentation [DATAROOTDIR/man]
50 | --docdir=DIR documentation root [DATAROOTDIR/doc/emacs]
51 | --htmldir=DIR html documentation [DOCDIR]
52 | --dvidir=DIR dvi documentation [DOCDIR]
53 | --pdfdir=DIR pdf documentation [DOCDIR]
54 | --psdir=DIR ps documentation [DOCDIR]
55 |
56 | Program names:
57 | --program-prefix=PREFIX prepend PREFIX to installed program names
58 | --program-suffix=SUFFIX append SUFFIX to installed program names
59 | --program-transform-name=PROGRAM run sed PROGRAM on installed program names
60 |
61 | X features:
62 | --x-includes=DIR X include files are in DIR
63 | --x-libraries=DIR X library files are in DIR
64 |
65 | System types:
66 | --build=BUILD configure for building on BUILD [guessed]
67 | --host=HOST cross-compile to build programs to run on HOST [BUILD]
68 |
69 | Optional Features:
70 | --disable-option-checking ignore unrecognized --enable/--with options
71 | --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no)
72 | --enable-FEATURE[=ARG] include FEATURE [ARG=yes]
73 | --disable-ns-self-contained
74 | disable self contained build under NeXTstep
75 | --enable-locallisppath=PATH
76 | directories Emacs should search for lisp files
77 | specific to this site
78 | --enable-checking[=LIST]
79 | enable expensive checks. With LIST, enable only
80 | specific categories of checks. Categories are:
81 | all,yes,no. Flags are: stringbytes, stringoverrun,
82 | stringfreelist, structs, glyphs
83 | --enable-profiling build emacs with low-level, gprof profiling support.
84 | Mainly useful for debugging Emacs itself. May not
85 | work on all platforms. Stops profiler.el working.
86 | --enable-autodepend automatically generate dependencies to .h-files.
87 | Requires gcc, enabled if found.
88 | --enable-gtk-deprecation-warnings
89 | Show Gtk+/Gdk deprecation warnings for Gtk+ >= 3.0
90 | --disable-build-details Make the build more deterministic by omitting host
91 | names, time stamps, etc. from the output.
92 | --disable-largefile omit support for large files
93 | --disable-year2038 omit support for timestamps past the year 2038
94 | --enable-gcc-warnings[=TYPE]
95 | control generation of GCC warnings. The TYPE 'yes'
96 | means to fail if any warnings are issued;
97 | 'warn-only' means issue warnings without failing
98 | (default for developer builds); 'no' means disable
99 | warnings (default for non-developer builds).
100 | --enable-check-lisp-object-type
101 | Enable compile time checks for the Lisp_Object data
102 | type, which can catch some bugs during development.
103 | --enable-link-time-optimization
104 | build with link-time optimization (experimental; see
105 | INSTALL)
106 | --disable-silent-rules verbose build output (undo: "make V=0")
107 | --enable-cross-guesses={conservative|risky}
108 | specify policy for cross-compilation guesses
109 | --disable-acl do not support ACLs
110 |
111 | Optional Packages:
112 | --with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
113 | --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no)
114 | --without-all omit almost all features and build small executable
115 | with minimal dependencies
116 | --with-mailutils rely on GNU Mailutils, so that the --without-pop
117 | through --with-mailhost options are irrelevant; this
118 | is the default if GNU Mailutils is installed
119 | --with-pop Support POP mail retrieval if Emacs movemail is used
120 | (not recommended, as Emacs movemail POP is
121 | insecure). This is the default only on native
122 | MS-Windows.
123 | --with-kerberos support Kerberos-authenticated POP
124 | --with-kerberos5 support Kerberos version 5 authenticated POP
125 | --with-hesiod support Hesiod to get the POP server host
126 | --with-mail-unlink unlink, rather than empty, mail spool after reading
127 | --with-mailhost=HOSTNAME
128 | string giving default POP mail host
129 | --with-sound=VALUE compile with sound support (VALUE one of: yes, alsa,
130 | oss, bsd-ossaudio, no; default yes). Only for
131 | GNU/Linux, FreeBSD, NetBSD, MinGW, Cygwin.
132 | --with-pdumper=VALUE enable pdumper support unconditionally ('yes', 'no',
133 | or 'auto': default 'auto')
134 | --with-unexec=VALUE enable unexec support unconditionally ('yes', 'no',
135 | or 'auto': default 'auto')
136 | --with-dumping=VALUE kind of dumping to use for initial Emacs build
137 | (VALUE one of: pdumper, unexec, none; default
138 | pdumper)
139 | --with-x-toolkit=KIT use an X toolkit (KIT one of: yes or gtk, gtk2,
140 | gtk3, lucid or athena, no)
141 | --with-wide-int prefer wide Emacs integers (typically 62-bit); on
142 | 32-bit hosts, this allows buffer and string size up
143 | to 2GB, at the cost of 10% to 30% slowdown of Lisp
144 | interpreter and larger memory footprint
145 | --without-xpm don't compile with XPM image support
146 | --without-jpeg don't compile with JPEG image support
147 | --without-tiff don't compile with TIFF image support
148 | --without-gif don't compile with GIF image support
149 | --without-png don't compile with PNG image support
150 | --without-rsvg don't compile with SVG image support
151 | --without-webp don't compile with WebP image support
152 | --without-lcms2 don't compile with Little CMS support
153 | --without-libsystemd don't compile with libsystemd support
154 | --without-cairo don't compile with Cairo drawing
155 | --without-xml2 don't compile with XML parsing support
156 | --with-imagemagick compile with ImageMagick image support
157 | --without-native-image-api
158 | don't use native image APIs (GDI+ on Windows)
159 | --with-json compile with native JSON support
160 | --without-xft don't use XFT for anti aliased fonts
161 | --without-harfbuzz don't use HarfBuzz for text shaping
162 | --without-libotf don't use libotf for OpenType font support
163 | --without-m17n-flt don't use m17n-flt for text shaping
164 | --without-toolkit-scroll-bars
165 | don't use Xaw3d/GTK toolkit scroll bars
166 | --without-xaw3d don't use Xaw3d
167 | --without-xim at runtime, default X11 XIM to off
168 | --without-xdbe don't use X11 double buffering support
169 | --with-ns use Nextstep (macOS Cocoa or GNUstep) windowing
170 | system. On by default on macOS.
171 | --with-w32 use native MS Windows GUI in a Cygwin build
172 | --without-gpm don't use -lgpm for mouse support on a GNU/Linux
173 | console
174 | --without-dbus don't compile with D-Bus support
175 | --with-gconf compile with Gconf support (Gsettings replaces this)
176 | --without-gsettings don't compile with GSettings support
177 | --without-selinux don't compile with SELinux support
178 | --without-gnutls don't use -lgnutls for SSL/TLS support
179 | --without-zlib don't compile with zlib decompression support
180 | --without-modules don't compile with dynamic modules support
181 | --without-threads don't compile with elisp threading support
182 | --with-native-compilation
183 | compile with Emacs Lisp native compiler support
184 | --with-cygwin32-native-compilation
185 | use native compilation on 32-bit Cygwin
186 | --with-xinput2 use version 2 of the X Input Extension for input
187 | --with-file-notification=LIB
188 | use a file notification library (LIB one of: yes,
189 | inotify, kqueue, gfile, w32, no)
190 | --with-xwidgets enable use of xwidgets in Emacs buffers (requires
191 | gtk3 or macOS Cocoa)
192 | --with-be-app enable use of Haiku's Application Kit as a window
193 | system
194 | --with-be-cairo enable use of cairo under Haiku's Application Kit
195 | --without-compress-install
196 | don't compress some files (.el, .info, etc.) when
197 | installing. Equivalent to: make GZIP_PROG= install
198 | --with-gameuser=USER_OR_GROUP
199 | user for shared game score files. An argument
200 | prefixed by ':' specifies a group instead.
201 | --with-gnustep-conf=FILENAME
202 | name of GNUstep configuration file to use on systems
203 | where the command 'gnustep-config' does not work;
204 | default $GNUSTEP_CONFIG_FILE, or
205 | /etc/GNUstep/GNUstep.conf
206 | --with-x use the X Window System
207 | --without-libgmp do not use the GNU Multiple Precision (GMP) library;
208 | this is the default on systems lacking libgmp.
209 | --without-included-regex
210 | don't compile regex; this is the default on systems
211 | with recent-enough versions of the GNU C Library
212 | (use with caution on other systems).
213 |
214 | Some influential environment variables:
215 | CC C compiler command
216 | CFLAGS C compiler flags
217 | LDFLAGS linker flags, e.g. -L if you have libraries in a
218 | nonstandard directory
219 | LIBS libraries to pass to the linker, e.g. -l
220 | CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I if
221 | you have headers in a nonstandard directory
222 | CPP C preprocessor
223 | PKG_CONFIG path to pkg-config utility
224 | PKG_CONFIG_PATH
225 | directories to add to pkg-config's search path
226 | PKG_CONFIG_LIBDIR
227 | path overriding pkg-config's built-in search path
228 | ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config
229 | ALSA_LIBS linker flags for ALSA, overriding pkg-config
230 | XMKMF Path to xmkmf, Makefile generator for X Window System
231 | OBJC Objective C compiler command
232 | OBJCFLAGS Objective C compiler flags
233 | CXX C++ compiler command
234 | CXXFLAGS C++ compiler flags
235 | RSVG_CFLAGS C compiler flags for RSVG, overriding pkg-config
236 | RSVG_LIBS linker flags for RSVG, overriding pkg-config
237 | WEBP_CFLAGS C compiler flags for WEBP, overriding pkg-config
238 | WEBP_LIBS linker flags for WEBP, overriding pkg-config
239 | IMAGEMAGICK_CFLAGS
240 | C compiler flags for IMAGEMAGICK, overriding pkg-config
241 | IMAGEMAGICK_LIBS
242 | linker flags for IMAGEMAGICK, overriding pkg-config
243 | GTK_CFLAGS C compiler flags for GTK, overriding pkg-config
244 | GTK_LIBS linker flags for GTK, overriding pkg-config
245 | WEBKIT_CFLAGS
246 | C compiler flags for WEBKIT, overriding pkg-config
247 | WEBKIT_LIBS linker flags for WEBKIT, overriding pkg-config
248 | DBUS_CFLAGS C compiler flags for DBUS, overriding pkg-config
249 | DBUS_LIBS linker flags for DBUS, overriding pkg-config
250 | GSETTINGS_CFLAGS
251 | C compiler flags for GSETTINGS, overriding pkg-config
252 | GSETTINGS_LIBS
253 | linker flags for GSETTINGS, overriding pkg-config
254 | GCONF_CFLAGS
255 | C compiler flags for GCONF, overriding pkg-config
256 | GCONF_LIBS linker flags for GCONF, overriding pkg-config
257 | GOBJECT_CFLAGS
258 | C compiler flags for GOBJECT, overriding pkg-config
259 | GOBJECT_LIBS
260 | linker flags for GOBJECT, overriding pkg-config
261 | LIBGNUTLS_CFLAGS
262 | C compiler flags for LIBGNUTLS, overriding pkg-config
263 | LIBGNUTLS_LIBS
264 | linker flags for LIBGNUTLS, overriding pkg-config
265 | LIBSYSTEMD_CFLAGS
266 | C compiler flags for LIBSYSTEMD, overriding pkg-config
267 | LIBSYSTEMD_LIBS
268 | linker flags for LIBSYSTEMD, overriding pkg-config
269 | JSON_CFLAGS C compiler flags for JSON, overriding pkg-config
270 | JSON_LIBS linker flags for JSON, overriding pkg-config
271 | KQUEUE_CFLAGS
272 | C compiler flags for KQUEUE, overriding pkg-config
273 | KQUEUE_LIBS linker flags for KQUEUE, overriding pkg-config
274 | GFILENOTIFY_CFLAGS
275 | C compiler flags for GFILENOTIFY, overriding pkg-config
276 | GFILENOTIFY_LIBS
277 | linker flags for GFILENOTIFY, overriding pkg-config
278 | CAIRO_CFLAGS
279 | C compiler flags for CAIRO, overriding pkg-config
280 | CAIRO_LIBS linker flags for CAIRO, overriding pkg-config
281 | FREETYPE_CFLAGS
282 | C compiler flags for FREETYPE, overriding pkg-config
283 | FREETYPE_LIBS
284 | linker flags for FREETYPE, overriding pkg-config
285 | FONTCONFIG_CFLAGS
286 | C compiler flags for FONTCONFIG, overriding pkg-config
287 | FONTCONFIG_LIBS
288 | linker flags for FONTCONFIG, overriding pkg-config
289 | XFT_CFLAGS C compiler flags for XFT, overriding pkg-config
290 | XFT_LIBS linker flags for XFT, overriding pkg-config
291 | LIBOTF_CFLAGS
292 | C compiler flags for LIBOTF, overriding pkg-config
293 | LIBOTF_LIBS linker flags for LIBOTF, overriding pkg-config
294 | M17N_FLT_CFLAGS
295 | C compiler flags for M17N_FLT, overriding pkg-config
296 | M17N_FLT_LIBS
297 | linker flags for M17N_FLT, overriding pkg-config
298 | HARFBUZZ_CFLAGS
299 | C compiler flags for HARFBUZZ, overriding pkg-config
300 | HARFBUZZ_LIBS
301 | linker flags for HARFBUZZ, overriding pkg-config
302 | LCMS2_CFLAGS
303 | C compiler flags for LCMS2, overriding pkg-config
304 | LCMS2_LIBS linker flags for LCMS2, overriding pkg-config
305 | PNG_CFLAGS C compiler flags for PNG, overriding pkg-config
306 | PNG_LIBS linker flags for PNG, overriding pkg-config
307 | XRANDR_CFLAGS
308 | C compiler flags for XRANDR, overriding pkg-config
309 | XRANDR_LIBS linker flags for XRANDR, overriding pkg-config
310 | XINERAMA_CFLAGS
311 | C compiler flags for XINERAMA, overriding pkg-config
312 | XINERAMA_LIBS
313 | linker flags for XINERAMA, overriding pkg-config
314 | XFIXES_CFLAGS
315 | C compiler flags for XFIXES, overriding pkg-config
316 | XFIXES_LIBS linker flags for XFIXES, overriding pkg-config
317 | XINPUT_CFLAGS
318 | C compiler flags for XINPUT, overriding pkg-config
319 | XINPUT_LIBS linker flags for XINPUT, overriding pkg-config
320 | LIBXML2_CFLAGS
321 | C compiler flags for LIBXML2, overriding pkg-config
322 | LIBXML2_LIBS
323 | linker flags for LIBXML2, overriding pkg-config
324 | LIBSECCOMP_CFLAGS
325 | C compiler flags for LIBSECCOMP, overriding pkg-config
326 | LIBSECCOMP_LIBS
327 | linker flags for LIBSECCOMP, overriding pkg-config
328 |
329 | Use these variables to override the choices made by `configure' or to help
330 | it to find libraries and programs with nonstandard names/locations.
331 |
332 | Report bugs to .
333 | GNU Emacs home page: .
334 | General help using GNU software: .
335 |
336 | 1
337 |
--------------------------------------------------------------------------------
/materials/emacs-big-sur.icns:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/mclear-tools/build-emacs-macos/22016737e34dea70457a0e8e3f129b99458b8fba/materials/emacs-big-sur.icns
--------------------------------------------------------------------------------
/materials/emacs-git-version.el:
--------------------------------------------------------------------------------
1 | ;;; emacs-git-version.el ---
2 |
3 | ;; Copyright © 2012 Sébastien Gross
4 |
5 | ;; Original Author: Sébastien Gross
6 | ;; Modified: Colin Mclear
7 | ;; Keywords: emacs,
8 | ;; Created: 2012-09-21;
9 | ;; Last changed: 12-03-2021 14:47:57
10 | ;; License: WTFPL, grab your copy here: http://sam.zoy.org/wtfpl/
11 |
12 | ;; This file is NOT part of GNU Emacs.
13 |
14 | ;;; Commentary:
15 | ;;
16 |
17 |
18 | ;;; Code:
19 |
20 | (defconst emacs-version-git-commit "@@GIT_COMMIT@@"
21 | "String giving the git sha1 from which this Emacs was built.
22 |
23 | SHA1 of git commit that was used to compile this version of
24 | emacs. The source used to compile emacs are taken from Savannah's
25 | git repository at `http://git.savannah.gnu.org/r/emacs.git' or
26 | git://git.savannah.gnu.org/emacs.git
27 |
28 | See both `http://emacswiki.org/emacs/EmacsFromGit' and
29 | `http://savannah.gnu.org/projects/emacs' for further
30 | information.")
31 |
32 | (provide 'emacs-git-version)
33 |
34 | ;; emacs-git-version.el ends here
35 |
--------------------------------------------------------------------------------
/materials/info.plist:
--------------------------------------------------------------------------------
1 |
19 |
20 |
21 |
22 |
23 |
24 | CFBundleDevelopmentRegion
25 | English
26 | CFBundleDocumentTypes
27 |
28 |
29 | CFBundleTypeExtensions
30 |
31 | text
32 | txt
33 |
34 | CFBundleTypeIconFile
35 | Text-icon.icns
36 | CFBundleTypeName
37 | Plain text document
38 | CFBundleTypeOSTypes
39 |
40 | TEXT
41 | utxt
42 |
43 | CFBundleTypeRole
44 | Editor
45 |
46 |
47 |
48 | CFBundleTypeExtensions
49 |
50 | erb
51 |
52 | CFBundleTypeIconFile
53 | Erb-icon.icns
54 | CFBundleTypeName
55 | Rails Erb View
56 | CFBundleTypeRole
57 | Editor
58 |
59 |
60 |
61 | CFBundleTypeExtensions
62 |
63 | ejs
64 |
65 | CFBundleTypeIconFile
66 | Ejs-icon.icns
67 | CFBundleTypeName
68 | Rails Ejs View
69 | CFBundleTypeRole
70 | Editor
71 |
72 |
73 |
74 | CFBundleTypeExtensions
75 |
76 | slim
77 |
78 | CFBundleTypeIconFile
79 | Slim-icon.icns
80 | CFBundleTypeName
81 | Slim Document
82 | CFBundleTypeRole
83 | Editor
84 |
85 |
86 |
87 | CFBundleTypeExtensions
88 |
89 | haml
90 |
91 | CFBundleTypeIconFile
92 | Haml-icon.icns
93 | CFBundleTypeName
94 | Haml Document
95 | CFBundleTypeRole
96 | Editor
97 |
98 |
99 |
100 | CFBundleTypeExtensions
101 |
102 | less
103 |
104 | CFBundleTypeIconFile
105 | Less-icon.icns
106 | CFBundleTypeName
107 | Less Stylesheet
108 | CFBundleTypeRole
109 | Editor
110 |
111 |
112 |
113 | CFBundleTypeExtensions
114 |
115 | sass
116 |
117 | CFBundleTypeIconFile
118 | SASS-icon.icns
119 | CFBundleTypeName
120 | Sass Stylesheet
121 | CFBundleTypeRole
122 | Editor
123 |
124 |
125 |
126 | CFBundleTypeExtensions
127 |
128 | scss
129 |
130 | CFBundleTypeIconFile
131 | SCSS-icon.icns
132 | CFBundleTypeName
133 | Scss Stylesheet
134 | CFBundleTypeRole
135 | Editor
136 |
137 |
138 |
139 | CFBundleTypeExtensions
140 |
141 | ps
142 |
143 | CFBundleTypeIconFile
144 | PostScript-icon.icns
145 | CFBundleTypeName
146 | PostScript Document
147 | CFBundleTypeRole
148 | Editor
149 |
150 |
151 |
152 | CFBundleTypeExtensions
153 |
154 | handlebars
155 |
156 | CFBundleTypeIconFile
157 | Handlebars-icon.icns
158 | CFBundleTypeName
159 | Handlebars Template
160 | CFBundleTypeRole
161 | Editor
162 |
163 |
164 |
165 | CFBundleTypeExtensions
166 |
167 | mustache
168 |
169 | CFBundleTypeIconFile
170 | Mustache-icon.icns
171 | CFBundleTypeName
172 | Mustache Template
173 | CFBundleTypeRole
174 | Editor
175 |
176 |
177 |
178 | CFBundleTypeExtensions
179 |
180 | dot
181 |
182 | CFBundleTypeIconFile
183 | Graphviz-icon.icns
184 | CFBundleTypeName
185 | Graphviz Dot
186 | CFBundleTypeRole
187 | Editor
188 |
189 |
190 |
191 | CFBundleTypeExtensions
192 |
193 | properties
194 |
195 | CFBundleTypeIconFile
196 | Properties-icon.icns
197 | CFBundleTypeName
198 | Java properties file
199 | CFBundleTypeRole
200 | Editor
201 |
202 |
203 |
204 | CFBundleTypeExtensions
205 |
206 | r
207 |
208 | CFBundleTypeIconFile
209 | R-icon.icns
210 | CFBundleTypeName
211 | R Source File
212 | CFBundleTypeRole
213 | Editor
214 |
215 |
216 |
217 | CFBundleTypeExtensions
218 |
219 | feature
220 |
221 | CFBundleTypeIconFile
222 | Cucumber-icon.icns
223 | CFBundleTypeName
224 | Cucumber .Feature File
225 | CFBundleTypeRole
226 | Editor
227 |
228 |
229 |
230 | CFBundleTypeExtensions
231 |
232 | org
233 |
234 | CFBundleTypeIconFile
235 | Org-icon.icns
236 | CFBundleTypeName
237 | Emacs Org Mode File
238 | CFBundleTypeRole
239 | Editor
240 |
241 |
242 |
243 | CFBundleTypeExtensions
244 |
245 | rhtml
246 |
247 | CFBundleTypeIconFile
248 | RHTML-icon.icns
249 | CFBundleTypeName
250 | Rails RHTML View
251 | CFBundleTypeRole
252 | Editor
253 |
254 |
255 |
256 | CFBundleTypeExtensions
257 |
258 | ini
259 |
260 | CFBundleTypeIconFile
261 | INI-icon.icns
262 | CFBundleTypeName
263 | Ini File
264 | CFBundleTypeRole
265 | Editor
266 |
267 |
268 |
269 | CFBundleTypeExtensions
270 |
271 | rng
272 |
273 | CFBundleTypeIconFile
274 | RelaxNG-icon.icns
275 | CFBundleTypeName
276 | RelaxNG XML Schema
277 | CFBundleTypeRole
278 | Editor
279 |
280 |
281 |
282 | CFBundleTypeExtensions
283 |
284 | scala
285 |
286 | CFBundleTypeIconFile
287 | Scala-icon.icns
288 | CFBundleTypeName
289 | Scala Source File
290 | CFBundleTypeRole
291 | Editor
292 |
293 |
294 |
295 | CFBundleTypeExtensions
296 |
297 | scheme
298 |
299 | CFBundleTypeIconFile
300 | Scheme-icon.icns
301 | CFBundleTypeName
302 | Scheme Source File
303 | CFBundleTypeRole
304 | Editor
305 |
306 |
307 |
308 | CFBundleTypeExtensions
309 |
310 | SQL
311 |
312 | CFBundleTypeIconFile
313 | SQL-icon.icns
314 | CFBundleTypeName
315 | SQL Source File
316 | CFBundleTypeRole
317 | Editor
318 |
319 |
320 |
321 | CFBundleTypeExtensions
322 |
323 | plist
324 |
325 | CFBundleTypeIconFile
326 | Plist-icon.icns
327 | CFBundleTypeName
328 | Apple Plist
329 | CFBundleTypeRole
330 | Editor
331 |
332 |
333 |
334 | CFBundleTypeExtensions
335 |
336 | pm
337 |
338 | CFBundleTypeIconFile
339 | PerlModule-icon.icns
340 | CFBundleTypeName
341 | Perl Module
342 | CFBundleTypeRole
343 | Editor
344 |
345 |
346 |
347 | CFBundleTypeExtensions
348 |
349 | mml
350 |
351 | CFBundleTypeIconFile
352 | MathML-icon.icns
353 | CFBundleTypeName
354 | Math Markup Language
355 | CFBundleTypeRole
356 | Editor
357 |
358 |
359 |
360 | CFBundleTypeExtensions
361 |
362 | coffee
363 |
364 | CFBundleTypeIconFile
365 | CoffeeScript-icon.icns
366 | CFBundleTypeName
367 | CoffeeScript Source File
368 | CFBundleTypeRole
369 | Editor
370 |
371 |
372 |
373 | CFBundleTypeExtensions
374 |
375 | rest
376 | rst
377 |
378 | CFBundleTypeIconFile
379 | reST-icon.icns
380 | CFBundleTypeName
381 | reStructured Text File
382 | CFBundleTypeRole
383 | Editor
384 |
385 |
386 |
387 | CFBundleTypeExtensions
388 |
389 | cs
390 |
391 | CFBundleTypeIconFile
392 | CSharp-icon.icns
393 | CFBundleTypeName
394 | C# Source File
395 | CFBundleTypeRole
396 | Editor
397 |
398 |
399 |
400 | CFBundleTypeExtensions
401 |
402 | erl
403 |
404 | CFBundleTypeIconFile
405 | Erlang-icon.icns
406 | CFBundleTypeName
407 | Erlang Source File
408 | CFBundleTypeRole
409 | Editor
410 |
411 |
412 |
413 | CFBundleTypeExtensions
414 |
415 | scm
416 | sch
417 |
418 | CFBundleTypeIconFile
419 | Scheme-icon.icns
420 | CFBundleTypeName
421 | Scheme Source File
422 | CFBundleTypeRole
423 | Editor
424 |
425 |
426 |
427 | CFBundleTypeExtensions
428 |
429 | cgi
430 | fcgi
431 |
432 | CFBundleTypeIconFile
433 | CGI-icon.icns
434 | CFBundleTypeName
435 | CGI Script
436 | CFBundleTypeRole
437 | Editor
438 |
439 |
440 |
441 | CFBundleTypeExtensions
442 |
443 | applescript
444 |
445 | CFBundleTypeIconFile
446 | AppleScript-icon.icns
447 | CFBundleTypeName
448 | AppleScript Source File
449 | CFBundleTypeRole
450 | Editor
451 |
452 |
453 |
454 | CFBundleTypeExtensions
455 |
456 | as
457 |
458 | CFBundleTypeIconFile
459 | ActionScript-icon.icns
460 | CFBundleTypeName
461 | ActionScript Source File
462 | CFBundleTypeRole
463 | Editor
464 |
465 |
466 |
467 | CFBundleTypeExtensions
468 |
469 | mxml
470 |
471 | CFBundleTypeIconFile
472 | FlexMxml-icon.icns
473 | CFBundleTypeName
474 | Flex MXML Source
475 | CFBundleTypeRole
476 | Editor
477 |
478 |
479 |
480 | CFBundleTypeExtensions
481 |
482 | aspx
483 | ascx
484 | asmx
485 | ashx
486 |
487 | CFBundleTypeIconFile
488 | Asp.NET-icon.icns
489 | CFBundleTypeName
490 | ASP.NET Dcoument
491 | CFBundleTypeRole
492 | Editor
493 |
494 |
495 |
496 | CFBundleTypeExtensions
497 |
498 | conf
499 | htaccess
500 | config
501 | cfg
502 |
503 | CFBundleTypeIconFile
504 | Conf-icon.icns
505 | CFBundleTypeName
506 | Config File
507 | CFBundleTypeRole
508 | Editor
509 |
510 |
511 |
512 | CFBundleTypeExtensions
513 |
514 | csv
515 |
516 | CFBundleTypeIconFile
517 | CSV-icon.icns
518 | CFBundleTypeName
519 | Comma Separated Values
520 | CFBundleTypeRole
521 | Editor
522 |
523 |
524 |
525 | CFBundleTypeExtensions
526 |
527 | svg
528 |
529 | CFBundleTypeIconFile
530 | SVG-icon.icns
531 | CFBundleTypeName
532 | Scalable Vector Graphics
533 | CFBundleTypeRole
534 | Editor
535 |
536 |
537 |
538 | CFBundleTypeExtensions
539 |
540 | vcard
541 | vcf
542 |
543 | CFBundleTypeIconFile
544 | VCard-icon.icns
545 | CFBundleTypeName
546 | Electronic Business Card
547 | CFBundleTypeRole
548 | Editor
549 |
550 |
551 |
552 | CFBundleTypeExtensions
553 |
554 | vb
555 |
556 | CFBundleTypeIconFile
557 | VisualBasic-icon.icns
558 | CFBundleTypeName
559 | VisualBasic Source
560 | CFBundleTypeRole
561 | Editor
562 |
563 |
564 |
565 | CFBundleTypeExtensions
566 |
567 | ml
568 | mli
569 | mll
570 | mly
571 |
572 | CFBundleTypeIconFile
573 | OCaml-icon.icns
574 | CFBundleTypeName
575 | OCaml Source
576 | CFBundleTypeRole
577 | Editor
578 |
579 |
580 |
581 | CFBundleTypeExtensions
582 |
583 | patch
584 |
585 | CFBundleTypeIconFile
586 | Patch-icon.icns
587 | CFBundleTypeName
588 | Patch File
589 | CFBundleTypeRole
590 | Editor
591 |
592 |
593 |
594 | CFBundleTypeExtensions
595 |
596 | mm
597 |
598 | CFBundleTypeIconFile
599 | Obj-C++-icon.icns
600 | CFBundleTypeName
601 | Objective-C++ Source File
602 | CFBundleTypeRole
603 | Editor
604 |
605 |
606 |
607 | CFBundleTypeExtensions
608 |
609 | moinmoin
610 |
611 | CFBundleTypeIconFile
612 | Wiki-icon.icns
613 | CFBundleTypeName
614 | MoinMoin Document
615 | CFBundleTypeRole
616 | Editor
617 |
618 |
619 |
620 | CFBundleTypeExtensions
621 |
622 | lisp
623 | l
624 | cl
625 | mud
626 |
627 | CFBundleTypeIconFile
628 | Lisp-icon.icns
629 | CFBundleTypeName
630 | Lisp Source
631 | CFBundleTypeRole
632 | Editor
633 |
634 |
635 |
636 |
637 | CFBundleTypeExtensions
638 |
639 | html
640 | htm
641 |
642 | CFBundleTypeIconFile
643 | HTML-icon.icns
644 | CFBundleTypeName
645 | HTML document
646 | CFBundleTypeOSTypes
647 |
648 | HTML
649 |
650 | CFBundleTypeRole
651 | Editor
652 |
653 |
654 | CFBundleTypeExtensions
655 |
656 | shtm
657 | shtml
658 |
659 | CFBundleTypeIconFile
660 | SHTML-icon.icns
661 | CFBundleTypeName
662 | SHTML document
663 | CFBundleTypeOSTypes
664 |
665 | SHTML
666 |
667 | CFBundleTypeRole
668 | Editor
669 |
670 |
671 | CFBundleTypeExtensions
672 |
673 | jsp
674 |
675 | CFBundleTypeIconFile
676 | JSP-icon.icns
677 | CFBundleTypeName
678 | JSP document
679 | CFBundleTypeOSTypes
680 |
681 | JSP
682 |
683 | CFBundleTypeRole
684 | Editor
685 |
686 |
687 | CFBundleTypeExtensions
688 |
689 | asp
690 | asa
691 |
692 | CFBundleTypeIconFile
693 | ASP-icon.icns
694 | CFBundleTypeName
695 | ASP document
696 | CFBundleTypeOSTypes
697 |
698 | ASP
699 |
700 | CFBundleTypeRole
701 | Editor
702 |
703 |
704 | CFBundleTypeExtensions
705 |
706 | markdown
707 | mkdn
708 |
709 | CFBundleTypeIconFile
710 | Markdown-icon.icns
711 | CFBundleTypeName
712 | Markdown document
713 | CFBundleTypeRole
714 | Editor
715 |
716 |
717 | CFBundleTypeExtensions
718 |
719 | css
720 |
721 | CFBundleTypeIconFile
722 | CSS-icon.icns
723 | CFBundleTypeName
724 | CSS style sheet
725 | CFBundleTypeRole
726 | Editor
727 |
728 |
729 | CFBundleTypeExtensions
730 |
731 | xhtml
732 | xhtm
733 |
734 | CFBundleTypeIconFile
735 | XHTML-icon.icns
736 | CFBundleTypeName
737 | XHTML document
738 | CFBundleTypeRole
739 | Editor
740 |
741 |
742 | CFBundleTypeExtensions
743 |
744 | xml
745 |
746 | CFBundleTypeIconFile
747 | XML-icon.icns
748 | CFBundleTypeName
749 | XML document
750 | CFBundleTypeRole
751 | Editor
752 |
753 |
754 | CFBundleTypeExtensions
755 |
756 | xsl
757 | xslt
758 |
759 | CFBundleTypeIconFile
760 | XSL-icon.icns
761 | CFBundleTypeName
762 | XSL document
763 | CFBundleTypeRole
764 | Editor
765 |
766 |
767 | CFBundleTypeExtensions
768 |
769 | xbl
770 | xul
771 |
772 | CFBundleTypeIconFile
773 | XUL-icon.icns
774 | CFBundleTypeName
775 | XUL document
776 | CFBundleTypeRole
777 | Editor
778 |
779 |
780 | CFBundleTypeExtensions
781 |
782 | rdf
783 |
784 | CFBundleTypeIconFile
785 | RDF-icon.icns
786 | CFBundleTypeName
787 | RDF document
788 | CFBundleTypeRole
789 | Editor
790 |
791 |
792 | CFBundleTypeExtensions
793 |
794 | dtd
795 |
796 | CFBundleTypeIconFile
797 | DTD-icon.icns
798 | CFBundleTypeName
799 | DTD document
800 | CFBundleTypeRole
801 | Editor
802 |
803 |
804 | CFBundleTypeExtensions
805 |
806 | xsd
807 | xsdl
808 |
809 | CFBundleTypeIconFile
810 | XSD-icon.icns
811 | CFBundleTypeName
812 | XSD document
813 | CFBundleTypeRole
814 | Editor
815 |
816 |
817 | CFBundleTypeExtensions
818 |
819 | sgml
820 | sgm
821 |
822 | CFBundleTypeIconFile
823 | SGML-icon.icns
824 | CFBundleTypeName
825 | SGML document
826 | CFBundleTypeRole
827 | Editor
828 |
829 |
830 | CFBundleTypeExtensions
831 |
832 | yml
833 | yaml
834 |
835 | CFBundleTypeIconFile
836 | YAML-icon.icns
837 | CFBundleTypeName
838 | YAML document
839 | CFBundleTypeRole
840 | Editor
841 |
842 |
843 | CFBundleTypeExtensions
844 |
845 | js
846 | JS
847 |
848 | CFBundleTypeIconFile
849 | JavaScript-icon.icns
850 | CFBundleTypeName
851 | JavaScript script
852 | CFBundleTypeRole
853 | Editor
854 |
855 |
856 | CFBundleTypeExtensions
857 |
858 | php
859 | php3
860 | php4
861 |
862 | CFBundleTypeIconFile
863 | PHP-icon.icns
864 | CFBundleTypeName
865 | PHP script
866 | CFBundleTypeRole
867 | Editor
868 |
869 |
870 | CFBundleTypeExtensions
871 |
872 | tcl
873 |
874 | CFBundleTypeIconFile
875 | Tcl-icon.icns
876 | CFBundleTypeName
877 | Tcl script
878 | CFBundleTypeRole
879 | Editor
880 |
881 |
882 | CFBundleTypeExtensions
883 |
884 | rb
885 | rbx
886 | rjs
887 | rxml
888 |
889 | CFBundleTypeIconFile
890 | Ruby-icon.icns
891 | CFBundleTypeName
892 | Ruby script
893 | CFBundleTypeRole
894 | Editor
895 |
896 |
897 | CFBundleTypeExtensions
898 |
899 | erbsql
900 |
901 | CFBundleTypeIconFile
902 | ErbSQL-icon.icns
903 | CFBundleTypeName
904 | SQL with embedded ruby
905 | CFBundleTypeRole
906 | Editor
907 |
908 |
909 |
910 | CFBundleTypeExtensions
911 |
912 | py
913 |
914 | CFBundleTypeIconFile
915 | Python-icon.icns
916 | CFBundleTypeName
917 | Python script
918 | CFBundleTypeRole
919 | Editor
920 |
921 |
922 | CFBundleTypeExtensions
923 |
924 | pl
925 |
926 | CFBundleTypeIconFile
927 | Perl-icon.icns
928 | CFBundleTypeName
929 | Perl script
930 | CFBundleTypeRole
931 | Editor
932 |
933 |
934 | CFBundleTypeExtensions
935 |
936 | sh
937 | csh
938 | bashrc
939 | bash_profile
940 | bash_login
941 | profile
942 | bash_logout
943 | zshrc
944 | bash_history
945 | zsh_history
946 |
947 | CFBundleTypeIconFile
948 | Shell-icon.icns
949 | CFBundleTypeName
950 | Shell script
951 | CFBundleTypeRole
952 | Editor
953 |
954 |
955 | CFBundleTypeExtensions
956 |
957 | h
958 | pch
959 |
960 | CFBundleTypeIconFile
961 | H-icon.icns
962 | CFBundleTypeName
963 | C Header Source File
964 | CFBundleTypeRole
965 | Editor
966 |
967 |
968 | CFBundleTypeExtensions
969 |
970 | c
971 |
972 | CFBundleTypeIconFile
973 | C-icon.icns
974 | CFBundleTypeName
975 | C Source File
976 | CFBundleTypeRole
977 | Editor
978 |
979 |
980 | CFBundleTypeExtensions
981 |
982 | hh
983 | hp
984 | hpp
985 | hxx
986 | h++
987 |
988 | CFBundleTypeIconFile
989 | H++-icon.icns
990 | CFBundleTypeName
991 | C++ Header Source File
992 | CFBundleTypeRole
993 | Editor
994 |
995 |
996 | CFBundleTypeExtensions
997 |
998 | cc
999 | cp
1000 | cpp
1001 | cxx
1002 | c++
1003 |
1004 | CFBundleTypeIconFile
1005 | C++-icon.icns
1006 | CFBundleTypeName
1007 | C++ Source File
1008 | CFBundleTypeRole
1009 | Editor
1010 |
1011 |
1012 | CFBundleTypeExtensions
1013 |
1014 | m
1015 |
1016 | CFBundleTypeIconFile
1017 | Obj-C-icon.icns
1018 | CFBundleTypeName
1019 | Objective-C Source File
1020 | CFBundleTypeRole
1021 | Editor
1022 |
1023 |
1024 | CFBundleTypeExtensions
1025 |
1026 | s
1027 | asm
1028 |
1029 | CFBundleTypeIconFile
1030 | ASM-icon.icns
1031 | CFBundleTypeName
1032 | Assembly Source File
1033 | CFBundleTypeRole
1034 | Editor
1035 |
1036 |
1037 | CFBundleTypeExtensions
1038 |
1039 | java
1040 | jav
1041 |
1042 | CFBundleTypeIconFile
1043 | Java-icon.icns
1044 | CFBundleTypeName
1045 | Java Source File
1046 | CFBundleTypeRole
1047 | Editor
1048 |
1049 |
1050 | CFBundleTypeExtensions
1051 |
1052 | f
1053 | for
1054 | f77
1055 | f90
1056 | f95
1057 | f99
1058 |
1059 | CFBundleTypeIconFile
1060 | Fortran-icon.icns
1061 | CFBundleTypeName
1062 | Fortran Source File
1063 | CFBundleTypeRole
1064 | Editor
1065 |
1066 |
1067 | CFBundleTypeExtensions
1068 |
1069 | pas
1070 | p
1071 |
1072 | CFBundleTypeIconFile
1073 | Pascal-icon.icns
1074 | CFBundleTypeName
1075 | Pascal Source file
1076 | CFBundleTypeRole
1077 | Editor
1078 |
1079 |
1080 | CFBundleTypeExtensions
1081 |
1082 | ada
1083 | adb
1084 | ads
1085 |
1086 | CFBundleTypeIconFile
1087 | ADA-icon.icns
1088 | CFBundleTypeName
1089 | Ada Source File
1090 | CFBundleTypeRole
1091 | Editor
1092 |
1093 |
1094 | CFBundleTypeExtensions
1095 |
1096 | asm
1097 |
1098 | CFBundleTypeIconFile
1099 | Asm-icon.icns
1100 | CFBundleTypeName
1101 | Asm Source File
1102 | CFBundleTypeRole
1103 | Editor
1104 |
1105 |
1106 | CFBundleTypeExtensions
1107 |
1108 | el
1109 |
1110 | CFBundleTypeIconFile
1111 | EmacsLisp-icon.icns
1112 | CFBundleTypeName
1113 | Emacs Lisp Source File
1114 | CFBundleTypeRole
1115 | Editor
1116 |
1117 |
1118 | CFBundleTypeExtensions
1119 |
1120 | hs
1121 | lhs
1122 |
1123 | CFBundleTypeIconFile
1124 | Haskell-icon.icns
1125 | CFBundleTypeName
1126 | Haskell Source File
1127 | CFBundleTypeRole
1128 | Editor
1129 |
1130 |
1131 | CFBundleTypeExtensions
1132 |
1133 | lua
1134 |
1135 | CFBundleTypeIconFile
1136 | Lua-icon.icns
1137 | CFBundleTypeName
1138 | Lua Source File
1139 | CFBundleTypeRole
1140 | Editor
1141 |
1142 |
1143 | CFBundleTypeExtensions
1144 |
1145 | pro
1146 |
1147 | CFBundleTypeIconFile
1148 | IDL-icon.icns
1149 | CFBundleTypeName
1150 | IDL Procedure File
1151 | CFBundleTypeRole
1152 | Editor
1153 |
1154 |
1155 | CFBundleTypeExtensions
1156 |
1157 | gp
1158 |
1159 | CFBundleTypeIconFile
1160 | GnuPlot.icns
1161 | CFBundleTypeName
1162 | gnuplot file
1163 | CFBundleTypeRole
1164 | Editor
1165 |
1166 |
1167 | CFBundleTypeExtensions
1168 |
1169 | bib
1170 |
1171 | CFBundleTypeIconFile
1172 | BibTeX-icon.icns
1173 | CFBundleTypeName
1174 | BibTeX document
1175 | CFBundleTypeRole
1176 | Editor
1177 |
1178 |
1179 | CFBundleTypeExtensions
1180 |
1181 | tex
1182 | ltx
1183 | ctx
1184 | latex
1185 | texi
1186 |
1187 | CFBundleTypeIconFile
1188 | TeX-icon.icns
1189 | CFBundleTypeName
1190 | TeX document
1191 | CFBundleTypeRole
1192 | Editor
1193 |
1194 |
1195 | CFBundleTypeExtensions
1196 |
1197 | *
1198 |
1199 | CFBundleTypeName
1200 | All
1201 | CFBundleTypeOSTypes
1202 |
1203 | ****
1204 |
1205 | CFBundleTypeRole
1206 | Viewer
1207 |
1208 |
1209 |
1210 | NSServices
1211 |
1212 |
1213 | NSMenuItem
1214 |
1215 | default
1216 | Emacs.app/New Buffer Containing Selection
1217 |
1218 | NSMessage
1219 | requestService
1220 | NSUserData
1221 | open-selection
1222 | NSPortName
1223 | Emacs
1224 | NSSendTypes
1225 |
1226 | NSStringPboardType
1227 |
1228 |
1229 |
1230 | NSMenuItem
1231 |
1232 | default
1233 | Emacs.app/Open Selected File
1234 |
1235 | NSMessage
1236 | requestService
1237 | NSUserData
1238 | open-file
1239 | NSPortName
1240 | Emacs
1241 | NSSendTypes
1242 |
1243 | NSStringPboardType
1244 |
1245 |
1246 |
1247 | NSMenuItem
1248 |
1249 | default
1250 | Emacs.app/Email Selection
1251 |
1252 | NSMessage
1253 | requestService
1254 | NSUserData
1255 | mail-selection
1256 | NSPortName
1257 | Emacs
1258 | NSSendTypes
1259 |
1260 | NSStringPboardType
1261 |
1262 |
1263 |
1264 | NSMenuItem
1265 |
1266 | default
1267 | Emacs.app/Send Email to Selected Address
1268 |
1269 | NSMessage
1270 | requestService
1271 | NSUserData
1272 | mail-to
1273 | NSPortName
1274 | Emacs
1275 | NSSendTypes
1276 |
1277 | NSStringPboardType
1278 |
1279 |
1280 |
1281 |
1282 | CFBundleExecutable
1283 | Emacs
1284 | CFBundleGetInfoString
1285 | Emacs 24.3.50 Copyright (C) 2013 Free Software Foundation, Inc.
1286 | CFBundleIconFile
1287 | Emacs.icns
1288 | CFBundleIdentifier
1289 | org.gnu.Emacs
1290 | CFBundleInfoDictionaryVersion
1291 | 6.0
1292 | CFBundleName
1293 | Emacs
1294 | CFBundlePackageType
1295 | APPL
1296 |
1297 | CFBundleShortVersionString
1298 | 24.3.50
1299 | CFBundleSignature
1300 | EMAx
1301 |
1302 | CFBundleVersion
1303 | 9.0
1304 | NSPrincipalClass
1305 | EmacsApp
1306 | CFBundleURLTypes
1307 |
1308 |
1309 | CFBundleURLName
1310 | Email Address URL
1311 | CFBundleURLSchemes
1312 |
1313 | mailto
1314 |
1315 |
1316 |
1317 | NSAppleEventsUsageDescription
1318 | Emacs requires permission to send some event to another application.
1319 | LSUIElement
1320 |
1321 |
1322 |
1323 |
--------------------------------------------------------------------------------
/patches/fix-window-role.patch:
--------------------------------------------------------------------------------
1 | From 614bc763e72bdd5b26add04338cacc6803e2a0d6 Mon Sep 17 00:00:00 2001
2 | From: Golem
3 | Date: Thu, 9 Jan 2020 07:22:17 +0200
4 | Subject: [PATCH] [patch] fix-window-role
5 |
6 | ---
7 | src/nsterm.m | 2 +-
8 | 1 file changed, 1 insertion(+), 1 deletion(-)
9 |
10 | diff --git a/src/nsterm.m b/src/nsterm.m
11 | index 6f9b208953..aa6c1d286f 100644
12 | --- a/src/nsterm.m
13 | +++ b/src/nsterm.m
14 | @@ -8768,7 +8768,7 @@ - (id)accessibilityAttributeValue:(NSString *)attribute
15 | NSTRACE ("[EmacsWindow accessibilityAttributeValue:]");
16 |
17 | if ([attribute isEqualToString:NSAccessibilityRoleAttribute])
18 | - return NSAccessibilityTextFieldRole;
19 | + return NSAccessibilityWindowRole;
20 |
21 | if ([attribute isEqualToString:NSAccessibilitySelectedTextAttribute]
22 | && curbuf && ! NILP (BVAR (curbuf, mark_active)))
23 | --
24 | 2.26.2
25 |
26 |
--------------------------------------------------------------------------------
/patches/libgccjit-patch.patch:
--------------------------------------------------------------------------------
1 | From d3c9dcd4cb1d30a27e1e618ea5a9f5c12e103720 Mon Sep 17 00:00:00 2001
2 | From: Boris Buliga
3 | Date: Tue, 9 Aug 2022 09:17:27 +0300
4 | Subject: [PATCH] fix MAC_LIBS inference after gcc 12 release
5 |
6 | NOTE: this patch is no longer needed for Emacs 30+; see issue #5
7 |
8 | ---
9 | configure.ac | 3 +--
10 | 1 file changed, 1 insertion(+), 2 deletions(-)
11 |
12 | diff --git a/configure.ac b/configure.ac
13 | index 1a264275bd..40777ba002 100644
14 | --- a/configure.ac
15 | +++ b/configure.ac
16 | @@ -4240,8 +4240,7 @@ if test "${with_native_compilation}" != "no"; then
17 | if test -n "`$BREW --prefix --installed libgccjit 2>/dev/null`"; then
18 | MAC_CFLAGS="-I$(dirname $($BREW ls -v libgccjit | \
19 | grep libgccjit.h))"
20 | - MAC_LIBS="-L$(dirname $($BREW ls -v libgccjit| \
21 | - grep -E 'libgccjit\.(so|dylib)$'))"
22 | + MAC_LIBS="-L$(dirname $($BREW ls -v libgccjit | grep -E 'libgccjit\.(so|dylib)$' | tail -1))"
23 | fi
24 | fi
25 |
26 | --
27 | 2.36.1
28 |
29 |
--------------------------------------------------------------------------------
/patches/lion-fullscreen.patch:
--------------------------------------------------------------------------------
1 | diff --git a/lisp/term/ns-win.el b/lisp/term/ns-win.el
2 | index b8baaa0..9d25ff3 100644
3 | --- a/lisp/term/ns-win.el
4 | +++ b/lisp/term/ns-win.el
5 | @@ -940,6 +940,10 @@ See the documentation of `create-fontset-from-fontset-spec' for the format.")
6 | (add-to-list 'frame-creation-function-alist '(ns . x-create-frame-with-faces))
7 | (add-to-list 'window-system-initialization-alist '(ns . ns-initialize-window-system))
8 |
9 | +(declare-function ns-toggle-fullscreen-internal "nsfns.m" ())
10 | +(defun ns-toggle-fullscreen ()
11 | + (interactive)
12 | + (ns-toggle-fullscreen-internal))
13 |
14 | (provide 'ns-win)
15 |
16 | diff --git a/src/nsfns.m b/src/nsfns.m
17 | index fac61d2..9dbbc47 100644
18 | --- a/src/nsfns.m
19 | +++ b/src/nsfns.m
20 | @@ -2580,6 +2580,21 @@ Value is t if tooltip was open, nil otherwise. */)
21 | return Qt;
22 | }
23 |
24 | +DEFUN ("ns-toggle-fullscreen-internal", Fns_toggle_fullscreen_internal, Sns_toggle_fullscreen_internal,
25 | + 0, 0, 0,
26 | + doc: /* Toggle fulscreen mode */)
27 | +()
28 | +{
29 | + struct frame *f = SELECTED_FRAME();
30 | + EmacsWindow *window = ns_get_window(f);
31 | +
32 | +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= MAC_OS_X_VERSION_10_7
33 | + [window toggleFullScreen:nil];
34 | +#endif
35 | +
36 | + return Qnil;
37 | +}
38 | +
39 |
40 | /* ==========================================================================
41 |
42 | @@ -2736,5 +2751,7 @@ be used as the image of the icon representing the frame. */);
43 | defsubr (&Sx_show_tip);
44 | defsubr (&Sx_hide_tip);
45 |
46 | + defsubr (&Sns_toggle_fullscreen_internal);
47 | +
48 | as_status = 0;
49 | as_script = Qnil;
50 |
51 |
52 |
--------------------------------------------------------------------------------
/patches/no-frame-refocus-cocoa.patch:
--------------------------------------------------------------------------------
1 | From 7c14b8b6e6d4ed5ee88b6fd2857a2f07057fc058 Mon Sep 17 00:00:00 2001
2 | From: Golem
3 | Date: Thu, 9 Jan 2020 07:21:55 +0200
4 | Subject: [PATCH] [patch] no-frame-refocus-cocoa
5 |
6 | ---
7 | src/frame.c | 9 ---------
8 | 1 file changed, 9 deletions(-)
9 |
10 | diff --git a/src/frame.c b/src/frame.c
11 | index c871e4fd99..470ab948bd 100644
12 | --- a/src/frame.c
13 | +++ b/src/frame.c
14 | @@ -2056,15 +2056,6 @@ delete_frame (Lisp_Object frame, Lisp_Object force)
15 | }
16 | }
17 | }
18 | -#ifdef NS_IMPL_COCOA
19 | - else
20 | - /* Under NS, there is no system mechanism for choosing a new
21 | - window to get focus -- it is left to application code.
22 | - So the portion of THIS application interfacing with NS
23 | - needs to know about it. We call Fraise_frame, but the
24 | - purpose is really to transfer focus. */
25 | - Fraise_frame (frame1);
26 | -#endif
27 |
28 | do_switch_frame (frame1, 0, 1, Qnil);
29 | sf = SELECTED_FRAME ();
30 | --
31 | 2.26.2
32 |
33 |
--------------------------------------------------------------------------------
/patches/show-git-sha1-in-version.patch:
--------------------------------------------------------------------------------
1 | diff --git a/lisp/version.el b/lisp/version.el
2 | index ea6f1b4..2676b6c 100644
3 | --- a/lisp/version.el
4 | +++ b/lisp/version.el
5 | @@ -62,7 +62,7 @@ Don't use this function in programs to choose actions according
6 | to the system configuration; look at `system-configuration' instead."
7 | (interactive "P")
8 | (let ((version-string
9 | - (format "GNU Emacs %s (build %s, %s%s%s%s)%s"
10 | + (format "GNU Emacs %s (build %s, %s%s%s%s%s)%s"
11 | emacs-version
12 | emacs-build-number
13 | system-configuration
14 | @@ -82,6 +82,9 @@ to the system configuration; look at `system-configuration' instead."
15 | (format ", %s scroll bars"
16 | (capitalize (symbol-name x-toolkit-scroll-bars)))
17 | "")
18 | + (if (boundp 'emacs-version-git-commit)
19 | + (format ", git sha1 %s" emacs-version-git-commit)
20 | + "")
21 | (if emacs-build-time
22 | (format-time-string (concat
23 | (if (called-interactively-p
24 |
--------------------------------------------------------------------------------
/patches/system-appearance.patch:
--------------------------------------------------------------------------------
1 | Patch to make emacs 28 aware of the macOS 10.14+ system appearance changes.
2 |
3 | From 6e73cd55ebfd3b0967357b3c3ead16d2f8539526 Mon Sep 17 00:00:00 2001
4 | From: "Nicolas G. Querol"
5 | Date: Wed, 11 Nov 2020 12:35:47 +0100
6 | Subject: [PATCH] Add `ns-system-appearance-change-functions' hook
7 |
8 | This implements a new hook, effective only on macOS >= 10.14 (Mojave),
9 | that is called when the system changes its appearance (e.g. from light
10 | to dark). Users can then implement functions that take this change
11 | into account, for instance to load a particular theme.
12 |
13 | Minor changes are also made to select the right "dark" appearance
14 | (NSAppearanceNameDarkAqua) on macOS versions >= 10.14, the previous one
15 | (NSAppearanceNameVibrantDark) being deprecated.
16 |
17 | * src/frame.h (enum ns_appearance_type): Add new
18 | "ns_appearance_dark_aqua" case.
19 |
20 | * src/nsfns.m (defun x-create-frame): Use "dark aqua" appearance on
21 | macOS >= 10.14.
22 |
23 | * src/nsterm.m:
24 | - (ns_set_appearance): Use "dark aqua" appearance on
25 | macOS >= 10.14, reset appearance to the system one
26 | if `ns-appearance' frame parameter is not set to
27 | either `dark' or `light'.
28 | - (initFrameFromEmacs): Use "dark aqua" appearance on
29 | macOS >= 10.14.
30 | - (EmacsApp) Add the `systemDidChangeAppearance' private method,
31 | as well as the appropriate Key-Value Observing calls to update
32 | the frame's appearance when the system (and thus the app's)
33 | appearance changes.
34 | - Add `ns-system-appearance-change-functions' hook variable and
35 | symbol, to allow users to add functions that react to the
36 | change of the system's appearance.
37 | - Add `ns-system-appearance' variable, to allow users to consult
38 | the current system appearance.
39 |
40 | Here is an example on how to use this new feature:
41 |
42 | (defun my/load-theme (appearance)
43 | "Load theme, taking current system APPEARANCE into consideration."
44 | (mapc #'disable-theme custom-enabled-themes)
45 | (pcase appearance
46 | ('light (load-theme 'tango t))
47 | ('dark (load-theme 'tango-dark t))))
48 |
49 | (add-hook 'ns-system-appearance-change-functions #'my/load-theme)
50 |
51 | The hook being run on each system appearance change as well as at
52 | startup time, Emacs should then always load the appropriate theme.
53 | ---
54 | src/frame.h | 3 +-
55 | src/nsfns.m | 13 ++++-
56 | src/nsterm.m | 153 ++++++++++++++++++++++++++++++++++++++++++++++-----
57 | 3 files changed, 153 insertions(+), 16 deletions(-)
58 |
59 | diff --git a/src/frame.h b/src/frame.h
60 | index a8ad011889..e7f7fdafe1 100644
61 | --- a/src/frame.h
62 | +++ b/src/frame.h
63 | @@ -71,7 +71,8 @@ #define EMACS_FRAME_H
64 | {
65 | ns_appearance_system_default,
66 | ns_appearance_aqua,
67 | - ns_appearance_vibrant_dark
68 | + ns_appearance_vibrant_dark,
69 | + ns_appearance_dark_aqua
70 | };
71 | #endif
72 | #endif /* HAVE_WINDOW_SYSTEM */
73 | diff --git a/src/nsfns.m b/src/nsfns.m
74 | index 07bcab1816..4766eb91ae 100644
75 | --- a/src/nsfns.m
76 | +++ b/src/nsfns.m
77 | @@ -1256,14 +1256,25 @@ Turn the input menu (an NSMenu) into a lisp list for tracking on lisp side.
78 | store_frame_param (f, Qundecorated, FRAME_UNDECORATED (f) ? Qt : Qnil);
79 |
80 | #ifdef NS_IMPL_COCOA
81 | +#ifndef NSAppKitVersionNumber10_14
82 | +#define NSAppKitVersionNumber10_14 1671
83 | +#endif
84 | tem = gui_display_get_arg (dpyinfo, parms, Qns_appearance, NULL, NULL,
85 | RES_TYPE_SYMBOL);
86 | if (EQ (tem, Qdark))
87 | - FRAME_NS_APPEARANCE (f) = ns_appearance_vibrant_dark;
88 | + if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_14)
89 | + {
90 | + FRAME_NS_APPEARANCE (f) = ns_appearance_dark_aqua;
91 | + }
92 | + else
93 | + {
94 | + FRAME_NS_APPEARANCE (f) = ns_appearance_vibrant_dark;
95 | + }
96 | else if (EQ (tem, Qlight))
97 | FRAME_NS_APPEARANCE (f) = ns_appearance_aqua;
98 | else
99 | FRAME_NS_APPEARANCE (f) = ns_appearance_system_default;
100 | +
101 | store_frame_param (f, Qns_appearance,
102 | (!NILP (tem) && !EQ (tem, Qunbound)) ? tem : Qnil);
103 |
104 | diff --git a/src/nsterm.m b/src/nsterm.m
105 | index 4bdc67c10b..0d2f3e0b2b 100644
106 | --- a/src/nsterm.m
107 | +++ b/src/nsterm.m
108 | @@ -1889,11 +1889,25 @@ Hide the window (X11 semantics)
109 | return;
110 |
111 | if (EQ (new_value, Qdark))
112 | - FRAME_NS_APPEARANCE (f) = ns_appearance_vibrant_dark;
113 | - else if (EQ (new_value, Qlight))
114 | - FRAME_NS_APPEARANCE (f) = ns_appearance_aqua;
115 | + {
116 | +#if MAC_OS_X_VERSION_MAX_ALLOWED >= 101400
117 | +#ifndef NSAppKitVersionNumber10_14
118 | +#define NSAppKitVersionNumber10_14 1671
119 | +#endif
120 | + if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_14)
121 | + FRAME_NS_APPEARANCE(f) = ns_appearance_dark_aqua;
122 | + else
123 | +#endif /* MAC_OS_X_VERSION_MAX_ALLOWED >= 101400 */
124 | + FRAME_NS_APPEARANCE(f) = ns_appearance_vibrant_dark;
125 | + }
126 | + else if (EQ(new_value, Qlight))
127 | + {
128 | + FRAME_NS_APPEARANCE (f) = ns_appearance_aqua;
129 | + }
130 | else
131 | - FRAME_NS_APPEARANCE (f) = ns_appearance_system_default;
132 | + {
133 | + FRAME_NS_APPEARANCE (f) = ns_appearance_system_default;
134 | + }
135 |
136 | [window setAppearance];
137 | #endif /* MAC_OS_X_VERSION_MAX_ALLOWED >= 101000 */
138 | @@ -5381,6 +5395,7 @@ Needs to be here because ns_initialize_display_info () uses AppKit classes.
139 |
140 | ========================================================================== */
141 |
142 | +static const void *kEmacsAppKVOContext = &kEmacsAppKVOContext;
143 |
144 | @implementation EmacsApp
145 |
146 | @@ -5626,6 +5641,18 @@ - (void)applicationDidFinishLaunching: (NSNotification *)notification
147 | object:nil];
148 | #endif
149 |
150 | +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101400
151 | + [self addObserver:self
152 | + forKeyPath:NSStringFromSelector(@selector(effectiveAppearance))
153 | + options:NSKeyValueObservingOptionInitial|NSKeyValueObservingOptionNew
154 | + context:&kEmacsAppKVOContext];
155 | +
156 | + pending_funcalls = Fcons(list3(Qrun_hook_with_args,
157 | + Qns_system_appearance_change_functions,
158 | + Vns_system_appearance),
159 | + pending_funcalls);
160 | +#endif
161 | +
162 | #ifdef NS_IMPL_COCOA
163 | /* Some functions/methods in CoreFoundation/Foundation increase the
164 | maximum number of open files for the process in their first call.
165 | @@ -5664,6 +5691,68 @@ - (void)antialiasThresholdDidChange:(NSNotification *)notification
166 | #endif
167 | }
168 |
169 | +- (void)observeValueForKeyPath:(NSString *)keyPath
170 | + ofObject:(id)object
171 | + change:(NSDictionary *)change
172 | + context:(void *)context
173 | +{
174 | +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101400
175 | + if (context == kEmacsAppKVOContext
176 | + && object == self
177 | + && [keyPath isEqualToString:
178 | + NSStringFromSelector (@selector(effectiveAppearance))])
179 | + [self systemAppearanceDidChange:
180 | + [change objectForKey:NSKeyValueChangeNewKey]];
181 | + else
182 | +#endif /* (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101400 */
183 | + [super observeValueForKeyPath:keyPath
184 | + ofObject:object
185 | + change:change
186 | + context:context];
187 | +}
188 | +
189 | +#if defined (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101400
190 | +#ifndef NSAppKitVersionNumber10_14
191 | +#define NSAppKitVersionNumber10_14 1671
192 | +#endif
193 | +- (void)systemAppearanceDidChange:(NSAppearance *)newAppearance
194 | +{
195 | +
196 | + if (NSAppKitVersionNumber < NSAppKitVersionNumber10_14)
197 | + return;
198 | +
199 | + NSAppearanceName appearance_name =
200 | + [newAppearance bestMatchFromAppearancesWithNames:@[
201 | + NSAppearanceNameAqua, NSAppearanceNameDarkAqua
202 | + ]];
203 | +
204 | + BOOL is_dark_appearance =
205 | + [appearance_name isEqualToString:NSAppearanceNameDarkAqua];
206 | + Vns_system_appearance = is_dark_appearance ? Qdark : Qlight;
207 | +
208 | + run_system_appearance_change_hook ();
209 | +}
210 | +
211 | +static inline void run_system_appearance_change_hook (void)
212 | +{
213 | + if (NILP (Vns_system_appearance_change_functions))
214 | + return;
215 | +
216 | + block_input ();
217 | +
218 | + bool owfi = waiting_for_input;
219 | + waiting_for_input = false;
220 | +
221 | + safe_call2 (Qrun_hook_with_args,
222 | + Qns_system_appearance_change_functions,
223 | + Vns_system_appearance);
224 | + Fredisplay(Qt);
225 | +
226 | + waiting_for_input = owfi;
227 | +
228 | + unblock_input ();
229 | +}
230 | +#endif /* (NS_IMPL_COCOA) && MAC_OS_X_VERSION_MAX_ALLOWED >= 101400 */
231 |
232 | /* Termination sequences:
233 | C-x C-c:
234 | @@ -5828,6 +5917,14 @@ - (void)applicationDidResignActive: (NSNotification *)notification
235 | ns_send_appdefined (-1);
236 | }
237 |
238 | +- (void)applicationWillTerminate:(NSNotification *)notification
239 | +{
240 | + NSTRACE ("[EmacsApp applicationWillTerminate:]");
241 | +
242 | + [self removeObserver:self
243 | + forKeyPath:NSStringFromSelector(@selector(effectiveAppearance))
244 | + context:&kEmacsAppKVOContext];
245 | +}
246 |
247 |
248 | /* ==========================================================================
249 | @@ -8805,17 +8902,26 @@ - (void)setAppearance
250 | #define NSAppKitVersionNumber10_10 1343
251 | #endif
252 |
253 | - if (NSAppKitVersionNumber < NSAppKitVersionNumber10_10)
254 | - return;
255 | -
256 | - if (FRAME_NS_APPEARANCE (f) == ns_appearance_vibrant_dark)
257 | - appearance =
258 | - [NSAppearance appearanceNamed:NSAppearanceNameVibrantDark];
259 | - else if (FRAME_NS_APPEARANCE (f) == ns_appearance_aqua)
260 | - appearance =
261 | - [NSAppearance appearanceNamed:NSAppearanceNameAqua];
262 | + if (NSAppKitVersionNumber < NSAppKitVersionNumber10_10)
263 | + return;
264 |
265 | - [self setAppearance:appearance];
266 | +#if MAC_OS_X_VERSION_MAX_ALLOWED >= 101400
267 | +#ifndef NSAppKitVersionNumber10_14
268 | +#define NSAppKitVersionNumber10_14 1671
269 | +#endif
270 | + if (NSAppKitVersionNumber >= NSAppKitVersionNumber10_14
271 | + && FRAME_NS_APPEARANCE(f) == ns_appearance_dark_aqua)
272 | + appearance = [NSAppearance appearanceNamed:NSAppearanceNameDarkAqua];
273 | + else
274 | +#endif /* MAC_OS_X_VERSION_MAX_ALLOWED >= 101400 */
275 | + if (FRAME_NS_APPEARANCE(f) == ns_appearance_vibrant_dark)
276 | + appearance =
277 | + [NSAppearance appearanceNamed:NSAppearanceNameVibrantDark];
278 | + else if (FRAME_NS_APPEARANCE (f) == ns_appearance_aqua)
279 | + appearance =
280 | + [NSAppearance appearanceNamed:NSAppearanceNameAqua];
281 | +
282 | + [self setAppearance:appearance];
283 | #endif /* MAC_OS_X_VERSION_MAX_ALLOWED >= 101000 */
284 | }
285 |
286 | @@ -9952,6 +10058,25 @@ Nil means use fullscreen the old (< 10.7) way. The old way works better with
287 | This variable is ignored on macOS < 10.7 and GNUstep. Default is t. */);
288 | ns_use_mwheel_momentum = YES;
289 |
290 | + DEFVAR_LISP ("ns-system-appearance", Vns_system_appearance,
291 | + doc: /* Current system appearance, i.e. `dark' or `light'.
292 | +
293 | +This variable is ignored on macOS < 10.14 and GNUstep. Default is nil. */);
294 | + Vns_system_appearance = Qnil;
295 | + DEFSYM(Qns_system_appearance, "ns-system-appearance");
296 | +
297 | + DEFVAR_LISP ("ns-system-appearance-change-functions",
298 | + Vns_system_appearance_change_functions,
299 | + doc: /* List of functions to call when the system appearance changes.
300 | +Each function is called with a single argument, which corresponds to the new
301 | +system appearance (`dark' or `light').
302 | +
303 | +This hook is also run once at startup.
304 | +
305 | +This variable is ignored on macOS < 10.14 and GNUstep. Default is nil. */);
306 | + Vns_system_appearance_change_functions = Qnil;
307 | + DEFSYM(Qns_system_appearance_change_functions, "ns-system-appearance-change-functions");
308 | +
309 | /* TODO: Move to common code. */
310 | DEFVAR_LISP ("x-toolkit-scroll-bars", Vx_toolkit_scroll_bars,
311 | doc: /* SKIP: real doc in xterm.c. */);
312 |
313 | base-commit: e5c481b61c26bcf83779db9fb3ac6b96bc50ab2e
314 | --
315 | 2.33.0
316 |
317 |
--------------------------------------------------------------------------------