Commit Graph

416 Commits

Author SHA1 Message Date
Justin M. Keyes f05a2891d3 build: rename build-related dirs
Problem:
Dirs "config", "packaging", and "third-party" are all closely related
but this is not obvious from the layout. This adds friction for new
contributors.

Solution:
- rename config/ to cmake.config/
- rename test/config/ to test/cmakeconfig/ because it is used in Lua
  tests: require('test.cmakeconfig.paths').
- rename packaging/ to cmake.packaging/
- rename third-party/ to cmake.deps/ (parallel with .deps/)
2022-06-28 04:02:29 -07:00
Christian Clason b7084fef4c
fix(build): strip trailing newline from variable (#19084)
Problem: #19029 added a new fallback that sets
`$MACOSX_DEPLOYMENT_TARGET` to the local macOS version via `sw_vers`.
However, the output included a newline, which broke the generated Ninja
build script.

Solution: use `OUTPUT_STRIP_TRAILING_WHITESPACE` for `execute_process`.
2022-06-25 13:45:20 +02:00
Carlo Cabrera b70f160414
build(deps): support universal builds on macOS
CMake can handle building universal binaries on macOS using the
`CMAKE_OSX_ARCHITECTURES` variable. Let's pass this variable to the
relevant dep builds. We use the `LIST_SEPARATOR` argument to prevent the
shell from interpreting the `;` that CMake uses as a list separator.

For dependencies that don't build using CMake, we only need to make sure
that the compiler is invoked with the correct `-arch` flags. The
compiler does the rest.

The only exception to this is the LuaJIT build, which we handle
separately as a special case.
2022-06-24 23:43:11 +08:00
Carlo Cabrera adcaf24f42
build(luajit): support universal builds on macOS
To build universal binaries on macOS, one typically only needs to pass
multiple `-arch` flags to `clang`.

Unfortunately, this strategy causes LuaJIT builds to fail. To work
around this, we build LuaJIT for each requested architecture
individually first and then use `lipo` to package each architecture
slice into a universal binary.

To be able to do this on an Intel macOS host or an M1 macOS host without
a Rosetta installation, we need some special flags in order to tell
LuaJIT that it is cross-compiling for a different target. See [1] for
details.

[1] https://luajit.org/install.html#cross
2022-06-24 23:34:57 +08:00
bfredl e3281d992e fix(tests): check for EOF on exit of nvim properly 2022-06-13 10:15:44 +02:00
dundargoc 3c7b91da10
build: remove CMAKE_CROSSCOMPILING code #18914
This is rarely, if ever, used and certainly not tested. It's likely this
isn't functional anymore.
2022-06-12 15:11:14 -07:00
Christian Clason d93ba03c71
build(deps): bump Luv to HEAD - 9f8038633 (#18834) 2022-06-02 11:13:42 +02:00
Christian Clason bfc85eab12
build(deps): bump Luv to HEAD - 02d703b42 (#18808) 2022-05-31 10:58:30 +02:00
James McCoy 4fab52908b
Merge pull request #18607 from dundargoc/build/mingw
restore mingw in cmake
2022-05-24 07:19:12 -04:00
Christian Clason cda0ef23cf
build(deps): bump LuaJIT to HEAD - 4ef96cff8 (#18656) 2022-05-20 19:19:37 +02:00
Christian Clason 2d27732029
build(deps): bump libuv to HEAD - 730e07e2f (#18606) 2022-05-18 11:22:46 +02:00
Dundar Goc a4c0c07043 revert: "ci: remove mingw job #18580"
This partially reverts commit f8af81445b.

The mingw parts of cmake was removed to see if it was still used
(ref: https://github.com/neovim/neovim/pull/18580). It turns out it is,
so this will fix that.

Closes: https://github.com/neovim/neovim/issues/18597
2022-05-17 17:07:45 +02:00
dundargoc f8af81445b
ci: remove mingw job #18580
Unnecessary CI builds increase the change of spurious failures, which are costly
noise. Of course, we should fix all legitimate bugs, but we also cannot
micro-manage every platform, so there needs to be a clear motivation for the CI
builds that we maintain.

Reasons against maintaining a mingw CI job:
1. The windows mingw build is slow.
2. Failures:
    - https://github.com/neovim/neovim/issues/18494
    - https://github.com/neovim/neovim/issues/18495
3. The mingw artifact is 10x bigger than the windows MSVC artifact:
   https://github.com/neovim/neovim/issues/10560
4. Our releases publish the MSVC (not mingw) artifact for Windows users:
   https://github.com/neovim/neovim/releases
5. Non-MSVCRT has limitations documented by libuv: http://docs.libuv.org/en/v1.x/process.html
   > On Windows file descriptors greater than 2 are available to the child process only if the child processes uses the MSVCRT runtime.

Closes https://github.com/neovim/neovim/issues/18551
2022-05-15 15:59:58 -07:00
bfredl 36613b888b refactor(eval): use Hashy McHashFace instead of gperf
this removes gperf as a build dependency
2022-05-12 20:01:04 +02:00
Christian Clason 39afa64eed
build(deps): bump Luv to HEAD - c51e7052e (#18510) 2022-05-11 08:58:06 +02:00
Christian Clason 95b7851f62
build(deps): bump LuaJIT to HEAD - 91bc6b8ad (#18378) 2022-05-04 08:38:07 +02:00
bfredl ad63b94b03 refactor(ui): simplify stdin handling 2022-05-02 22:19:41 +02:00
kylo252 651b595271 build: bump msgpack to 4.0.0
see https://github.com/msgpack/msgpack-c/releases/tag/c-4.0.0
2022-05-01 13:40:10 +02:00
erw7 5f3018fa1a
refactor(terminal)!: drop winpty, require Windows 10 #18253
Problem:
winpty is only needed for Windows 8.1. Removing it reduces our build and code
complexity.

Solution:
- Remove winpty.
- Require Windows 10.

closes #18252
2022-04-26 21:17:06 -07:00
Christian Clason d3603e157a
build(deps): bump LuaJIT to HEAD - 5e3c45c43 (#18027) 2022-04-08 16:59:40 +02:00
Christian Clason d72e82d3db
build(deps): bump luajit to commit e2c312e (#17111)
bump bundled LuaJIT to e2c312e0de
2022-03-25 17:42:32 +01:00
Christian Clason 1e7ba7ea6b build(deps): bump libuv to 1.44.1 2022-03-10 16:48:49 +01:00
Christian Clason 8bae974da3
build(deps): bump tree-sitter to 0.20.6 (#17587) 2022-03-07 23:48:33 +01:00
Christian Clason c400688752
build(deps): bump libuv to 1.44.0 (#17613) 2022-03-07 22:49:35 +01:00
Dundar Göc eb4ae060bc build(cmake): remove unused variable CMAKE_CXX_COMPILER to fix warning 2022-03-04 19:21:35 +01:00
Dundar Göc f9a8a811c7 revert: "build(deps): bump libuv to 1.43.0+7ae0c95"
This reverts commit 2da9450de5.
2022-03-04 16:24:17 +01:00
Christian Clason 2da9450de5 build(deps): bump libuv to 1.43.0+7ae0c95 2022-02-26 12:06:02 +01:00
Christian Clason b857bc770b build(deps): bump luv to 1.43.0-0 2022-02-26 12:00:45 +01:00
James McCoy 921162a4b1 ci: bump Windows image to windows-2019
The VS 2019 CMake generator no longer has different generator types for
different architectures.  Now, the architecture is specified via CMake's
`-A` switch.  However, this requires we also propagate
`${CMAKE_GENERATOR_PLATFORM}` to the bundled deps, so they build for the
same architecture as Nvim.
2022-02-20 10:18:45 +01:00
Andreas Schneider 40c36efdee chore(deps): use https for downloading libvterm and libtermkey 2022-02-08 11:18:49 +01:00
Christian Clason db9cfb18e1 build(deps): bump tree-sitter to v0.20.3
this version contains massive performance improvements as well as a new
`--abi` flag that allows generating backward compatible parsers
2022-01-22 09:02:06 +01:00
Christian Clason 45f7fc9b06 build(deps): bump tree-sitter
update tree-sitter to
2346570901
which includes a massive performance improvement to query construction
(bumping ABI compatibility to 14; parsers need to be generated with a
flag to take advantage of this)
2022-01-18 09:07:12 +01:00
Christian Clason 5d15829c2b build(deps): bump treesitter to commit bf210f0
Update to bf210f0c9e, which is a significant improvement to query performance.
2022-01-12 17:04:00 +01:00
Christian Clason 302beaa36b
build(deps): bump tree-sitter to v0.20.2 (#16863) 2022-01-01 17:59:00 +01:00
Christian Clason 95803f0e90
build(deps): bump luajit to commit 1d20f33 (#16712)
fixes a bug with jit.bcsave on Windows (cf. #16631)
2021-12-18 19:09:00 +01:00
kylo252 2abd17813e
fix(build): install luajit modules on windows (#16658) 2021-12-18 10:53:27 -07:00
Christian Clason aad2437fc0 build(deps): bump tree-sitter commit
bump tree-sitter to 25f64e1eb6
to fix query performance regression in 0.20.1
2021-12-10 16:07:03 +01:00
dundargoc caa6992a10
chore: fix typos (#16361)
Co-authored-by: Brede Yabo Sherling Kristensen <bredeyabo@hotmail.com>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Co-authored-by: István Donkó <istvan.donko@gmail.com>
Co-authored-by: Julian Berman <Julian@GrayVines.com>
Co-authored-by: bryant <bryant@users.noreply.github.com>
Co-authored-by: Michael Lingelbach <m.j.lbach@gmail.com>
Co-authored-by: nlueb <9465658+nlueb@users.noreply.github.com>
Co-authored-by: Leonhard Saam <leonhard.saam@yahoo.com>
Co-authored-by: Jesse Wertheim <jaawerth@gmail.com>
Co-authored-by: dm1try <me@dmitry.it>
Co-authored-by: Jakub Łuczyński <doubleloop@o2.pl>
Co-authored-by: Louis Lebrault <louis.lebrault@gmail.com>
Co-authored-by: Brede Yabo Sherling Kristensen <bredeyabo@hotmail.com>
Co-authored-by: zeertzjq <zeertzjq@outlook.com>
Co-authored-by: István Donkó <istvan.donko@gmail.com>
Co-authored-by: Julian Berman <Julian@GrayVines.com>
Co-authored-by: bryant <bryant@users.noreply.github.com>
Co-authored-by: Michael Lingelbach <m.j.lbach@gmail.com>
Co-authored-by: nlueb <9465658+nlueb@users.noreply.github.com>
Co-authored-by: Leonhard Saam <leonhard.saam@yahoo.com>
Co-authored-by: Jesse Wertheim <jaawerth@gmail.com>
Co-authored-by: dm1try <me@dmitry.it>
Co-authored-by: Jakub Łuczyński <doubleloop@o2.pl>
Co-authored-by: Louis Lebrault <louis.lebrault@gmail.com>
2021-11-27 11:10:48 -05:00
Christian Clason faae47eddb build(deps): also bump treesitter-c to v0.20.1 2021-11-22 11:05:24 +01:00
Christian Clason e1cea4b38d build(deps): bump tree-sitter to 0.20.1 2021-11-22 10:26:17 +01:00
Christian Clason cab542c0f9 build(deps): bump luarocks to 3.8.0 2021-11-18 18:55:36 +01:00
erw7 0503e17375 fix(build): fix build failure in MinGW
The new MinGW fails to build libuv due to a typedef conflict between
mstcpip.h and src/win/winapi.h. This change avoids conflicts by disabling
typedef in the MinGW header.
2021-11-01 00:07:16 +09:00
Christian Clason eb6a1039c5
fix(build): remove amalg build target for LuaJIT (#16178)
fixup for #16041 (`amalg` build is recommended by LuaJIT for performance
but this way of doing it breaks parallel build with `make -j`)
2021-10-30 12:10:19 +02:00
Christian Clason 615e03c33e
build(deps): bump luv to 1.42.0-1 (#16113)
* Use uv_handle_size/uv_req_size instead of sizeof
* LuaJIT: add missing LJ_ENDIAN and LJ_NO_UNWIND checks for DASM [fixes building on aarch64]
2021-10-29 17:55:21 +02:00
Christian Clason 6acfbd810d
build(deps): bump luajit to latest commit (#16041)
bump LuaJIT to b4b2dce9fc
now requires `-funwind-tables` build flag, which conflicts with
`-DLUA_USE_ASSERT`
2021-10-29 17:54:59 +02:00
Jakub Łuczyński 035d82e0d3
build: update cmake min version to 3.10 #16065
* build(cmake): update cmake min version to 3.10
* ci: test cmake minimum required version
* build(cmake): remove some legacy includes
  * Since version 3.5 cmake_parse_arguments is implemented natively.
2021-10-19 19:19:33 -07:00
Björn Linse 7356d3cdbd
Merge pull request #15316 from vigoux/ts-fix-captures
fix(treesitter): run predicates more often in iter_matches
2021-10-07 16:00:36 +02:00
Christian Clason f6c0a37b02
build(deps)!: use libuv 1.42.0 upstream for WIN32 (#15889)
Switch libuv from https://github.com/neovim/libuv fork to upstream for WIN32.
Upstream at 1.42.0 is now used for all platforms.

BREAKING CHANGE: removes Windows 7 support
BREAKING CHANGE: removes support for mouse and alternate buffers in TUI for
Windows 8 and 8.1
2021-10-05 17:23:42 +02:00
Thomas Vigouroux 458f2aad5c
fix(treesitter): run predicates more often in iter_matches
Superseedes #15126, and fixes the issue.
2021-10-01 09:20:35 +02:00
Christian Clason aba397991b
build(deps): bump luarocks to 3.7.0 #15740
Besides bugfixes, this brings `XDG_*` compliance and improved
robustness, especially for network errors.

See https://github.com/luarocks/luarocks/blob/master/CHANGELOG.md

- fixup: set LIBUV_LIBDIR to workaround 83126ba324
    - https://github.com/luarocks/luarocks/issues/1214
    - https://github.com/luarocks/luarocks/pull/1355
2021-09-22 12:26:01 -07:00