Commit Graph

40 Commits

Author SHA1 Message Date
andy5995 f9da31ce61 docs: add gcc to list of compilers with sanitize tools 2023-02-23 16:18:02 -05:00
John Ericson 01a7aa0a4d Document and test env vars a bit better 2022-04-03 10:58:03 -07:00
Darren Ng af9af219d8 [skip ci] fix syntax typo 2022-03-04 19:59:39 -08:00
Volker Weißmann 2c079d855e Added warning if run_command is called without the check kwarg 2021-10-30 22:26:28 -04:00
Daniel Mensinger a216de4898 docs: Remove the deleted function find_library 2021-08-18 21:56:45 +03:00
Patryk Obara 1db49240c6
docs: Provide working instructions for scan-build [skip ci]
Replace `meson compile scan-build` with `ninja -C dir scan-build`,
because scan-build target does not work with `meson compile`.

Note about SCANBUILD env variable was not precise enough to describe how
to pass arguments to scan-build - provide an example to make it clear.

Fixes: #7644.
2021-03-28 21:16:08 +03:00
Luke Drummond 46e3480f7c Introduce `fs.read` to read a file as a string
Following #7890, this patch introduces the ability to read the contents
of a file to the fs module.

This patch introduces the ability to read files at configure time, but
has some restrictions:
    - binary files are not supported (I don't think this will prove a
    problem, and if people are wanting to do something with binary
    files, they should probably be shelling out to their own script).
    - Only files outside the build directory allowed. This limitation
      should prevent build loops.
Given that reading an arbitrary file at configure time can affect the
configuration in almost arbitrary ways, meson should force a reconfigure
when the given file changes. This is non-configurable, but this can
easily be changed with a future keyword argument.
2021-02-04 17:34:11 +00:00
Jussi Pakkanen 474f4813c4 Capitalize "Meson" consistently as it is a proper name. [skip ci] 2021-01-31 19:49:20 +00:00
Jussi Pakkanen f72ee8e742 Rewrap long text lines in docs. [skip ci] 2021-01-30 16:19:59 +00:00
Nathan Lanza 4b728293cd
Replace `dynamic linker` with `linker` [skip ci]
This header erroneously referred to the dynamic linker while the paragraph talks about
the "link editor." Change the title to account for the difference.
2020-07-14 20:48:11 +03:00
TheQwertiest 83a973ca04 Replaced `ninja` with `meson` [skip ci] 2020-06-30 23:52:31 +03:00
Jussi Pakkanen 1309b06183
Merge pull request #7196 from cconverse711/llvm-cov
coverage: llvm-cov support
2020-06-18 18:57:25 +03:00
TheQwertiest 96609da8d2 docs: replaced `ninja` with appropriate `meson` commands [skip ci] 2020-06-18 17:47:10 +03:00
Cary Converse a198e5d191 coverage: llvm-cov support 2020-06-17 23:02:50 -04:00
Dylan Baker 66f3ba9fd0 Docs: Make the suggested use for the not-found dependency better [skip ci] 2020-05-14 13:32:46 -07:00
Dylan Baker 7ad8b5f221 docs: Add a Howto about the null dependency [skip ci] 2020-05-14 01:59:34 +03:00
Jussi Pakkanen 7924e5f9c2 Revert "Naturally use env vars a bit more to match Autoconf"
This reverts commit 097dfc085e.
2020-03-23 18:07:24 +02:00
John Ericson 097dfc085e Naturally use env vars a bit more to match Autoconf
PR #6363 made it so our interpretation of env vars no longer clashed
with Autoconf's: if both Meson and Autoconf would read and env var, both
would do the same things with the value they read.

However, there were still cases that autoconf would read an env var when
meson wouldn't:

 - Autoconf would use `CC` in cross builds too

 - Autoconf would use `CC_FOR_BUILD` in native builds too.

There's no reason Meson can't also do this--if native cross files
overwrite rather than replace env vars, cross files can also overwrite
rather than replace env vars.

Because variables like `CC` are so ubiquitous, and because ignoring them
in cross builds just makes those builds liable to break (and things more
complicated in general), we bring Meson's behavior in line with
Autoconf's.
2020-03-23 17:51:36 +02:00
John Ericson 3a4388e51d Fix legacy env var support with cross
Fix #3969
2020-03-23 17:51:36 +02:00
Dylan Baker 9074c7f8a4 envconfig: Make compiler and linker environment variables match 2020-03-17 10:40:39 -07:00
Nirbheek Chauhan 03bfc47ebf docs: Update documentation about linker selection
We missed this in https://github.com/mesonbuild/meson/pull/6457
2020-02-14 08:51:41 +05:30
Dylan Baker b16a7ff454 docs: small cleanups and clarifications to setting the dynamic linker [skip ci]
Fixes #6510
2020-01-27 22:16:23 +02:00
Dylan Baker 730a7b296f environment: Replace LD with <LANG>LD
The rust code is ugly, because rust is annoying. It doesn't invoke a
linker directly (unless that linker is link.exe or lld-link.exe),
instead it invokes the C compiler (gcc or clang usually) to do it's
linking. Meson doesn't have good abstractions for this, though we
probably should because some of the D compilers do the same thing.
Either that or we should just call the c compiler directly, like vala
does.

This changes the public interface for meson, which we don't do unless we
absolutely have to. In this case I think we need to do it. A fair number
of projects have already been using 'ld' in their cross/native files to
get the ld binary and call it directly in custom_targets or generators,
and we broke that. While we could hit this problem again names like
`c_ld` and `cpp_ld` are far less likely to cause collisions than `ld`.
Additionally this gives a way to set the linker on a per-compiler basis,
which is probably in itself very useful.

Fixes #6442
2020-01-22 23:39:33 +02:00
Dylan Baker 32e0bcc516 docs: Update docs for LD and ld entries 2019-12-02 16:39:06 -08:00
mayl 33a2e7c3d2 Document lack of clang support [skip ci]
Meson doesn't currently provide a very helpful message when trying to generate a coverage report with clang, and in fact just silently fails for 2 of the 3 reports.  Ideally Meson would support coverage with llvm-cov, or provide a more helpful error message.  Until then, it seems it would be helpful to at least put a warning in the documentation
2019-11-10 23:47:02 +02:00
Daniel Mensinger e1a83793ae CMake: Added support for CMAKE_MODULE_PATH and extra CMake args (closes #4779) 2019-02-01 00:25:21 +02:00
Dylan Baker 4a8e8b7103 docs: further specify that CFLAGS and friends are only for distro packagers [skip ci] 2019-01-08 11:40:25 -08:00
Jussi Pakkanen 87871e7b95 Update documentation about compiler envvars and cross files. [skip ci] 2018-06-24 21:19:49 +03:00
Marvin Scholz 1c8d4bf05b Docs: Correct env variable SCAN_BUILD to SCANBUILD 2018-03-20 22:28:07 +02:00
Christoph Behle c653936700 Documentation: Add note about SCAN_BUILD
When running ninja scan-build you can use the environment variable
SCAN_BUILD to choose the right executable.
2017-11-19 18:17:31 +02:00
Kevin Anderson 562c50f229 Update references from mesonconf to meson configure
Fixes #2372
2017-10-23 18:43:39 +02:00
Luis Menina 36eb7bf0aa docs: Markdown headers don't need trailing hash signs
This is a cosmetic change because github seems to interpret those
correctly. Nonetheless, it adds unnecessary noise and makes people
modifying the pages think it might be needed.

See syntax guide at https://guides.github.com/features/mastering-markdown/
2017-10-23 18:43:04 +02:00
Gabríel Arthúr Pétursson d5e47ade80 doc: Mention that C/C++ language versions can be set per-target 2017-07-04 16:54:59 -04:00
Peter Hutterer a576791064 Use American English - 'ise' -> 'ize' where applicable 2017-05-04 22:09:27 +03:00
Peter Hutterer ca924451ac Use American English: behaviour -> behavior 2017-05-04 22:09:27 +03:00
Elliott Sales de Andrade 40d7704cd5 doc: Use https links wherever possible. 2017-05-03 16:20:53 -04:00
Elliott Sales de Andrade f3ad633f55 doc: Fix several minor typos. 2017-05-03 16:20:53 -04:00
Elliott Sales de Andrade b80d40c287 doc: Capitalize things more consistently.
Upper or lower case depending on the official spelling, or the more
consistent usage.
2017-05-03 16:20:51 -04:00
Mathieu Duponchelle b983d091e6 howtox.md: fix header hierarchy
.. and remove an obsolete wiki home link at the bottom of the page
2017-04-28 23:01:38 +03:00
Thibault Saunier b371875e02 docs: Import the website and wiki and build with hotdoc
This allows us to more easily have the documentation in sync with
the source code as people will have to document new features etc
right at the time where they implement it.
2017-04-26 17:56:33 +03:00