You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Revert "Update minimum rust version to 1.82.0"
This reverts commit 373a0e5.
* Have bindgen generate code suitable for compiling with rustc 1.72.0
* Avoid linux warnings
* Avoid linux warnings
@@ -29,74 +26,61 @@ You can find the browseable docs for the latest release on [docs.rs](https://doc
29
26
NOTE: `master` branch (code and docs) can differ from those docs prior to a new release.
30
27
31
28
# Minimum rust version
32
-
33
29
The minimum rust version required, by version:
34
-
35
-
* libproc-rs: 0.14.6 --> 1.74.1
30
+
* libproc-rs: 0.14.6 --> 1.74.1
36
31
* libproc-rs: 0.14.7 --> 1.72.0
37
-
* libproc-rs: 0.14.10 --> 1.82.0
38
32
39
33
This is tested in CI and must pass.
40
34
41
35
# Test Matrix
42
-
43
36
The Github Actions CI test `libproc-rs` on :
44
37
45
38
rust versions:
46
-
47
39
*`stable` (must pass)
48
40
*`beta` (must pass)
49
-
*`1.82.0` (currently the minimum rust version supported) (must pass)
50
-
*`nightly` (allowed to fail)
41
+
*`1.72.0` (currently the minimum rust version supported) (must pass)
42
+
*`nightly` (allowed to fail)
51
43
52
44
on the following platforms:
53
-
54
45
*`ubuntu-latest`
55
46
*`macos-12` (Monterey) (Intel)
56
47
*`macos-13` (Ventura) (Intel)
57
48
*`macos-14` (Sonoma) (Arm64)
58
49
59
50
# Examples
60
-
61
51
Two simple examples are included to show libproc-rs working.
62
52
63
53
-`procinfo` that takes a PID as an optional argument (uses it's own pid if none supplied) and returns
64
54
information about the process on stdout
65
55
-`dmesg` is a version of dmesg implemented in rust that uses libproc-rs.
66
56
67
57
These can be ran thus:
68
-
`sudo cargo run --example procinfo` or
58
+
`sudo cargo run --example procinfo` or
69
59
`sudo cargo run --example dmesg`
70
60
71
61
# Contributing
72
-
73
62
You are welcome to fork this repo and make a pull request, or write an issue.
74
63
75
64
## Experiment in OSS funding
76
-
77
-
I am exploring the ideas around Open Source Software funding from [RadWorks Foundation]([https://radworks.org/) via
78
-
the [Drips Project](https://www.drips.network/)
65
+
I am exploring the ideas around Open Source Software funding from [RadWorks Foundation]([https://radworks.org/) via the [Drips Project](https://www.drips.network/)
79
66
80
67
This project is in Drips [here](https://www.drips.network/app/projects/github/andrewdavidmackenzie/libproc-rs)
81
68
82
69
## Input Requested
83
-
84
70
* Suggestions for API, module re-org and cross-platform abstractions are welcome.
85
71
* How to do error reporting? Define own new Errors, or keep simple with Strings?
86
72
* Would like Path/PathBuf returned when it makes sense instead of String?
87
73
88
74
## TODO
89
-
90
-
See the [list of issues](https://github.com/andrewdavidmackenzie/libproc-rs/issues).
75
+
See the [list of issues](https://github.com/andrewdavidmackenzie/libproc-rs/issues).
91
76
I put the "help wanted" label where I need help from others.
92
-
77
+
93
78
- Look at what similar methods could be implemented as a starting poon Linux
94
79
- Complete the API on Mac OS X - figuring out all the Mac OS X / Darwin version mess....
95
80
- Add more documentation (including samples with documentation test)
96
81
- Add own custom error type and implement From::from to ease reporting of multiple error types in clients
97
82
98
83
## Build and Test Locally
99
-
100
84
If you're feeling lucky today, start with `make` that will run `clippy`, `test` and will build docs also.
101
85
102
86
If you want to stay "pure rust" : `cargo test` will build and test as usual.
@@ -112,34 +96,29 @@ In order to have tests pass when run as `root` or not, some tests need to check
112
96
at run-time (using our own `am_root()` function is handy) and avoid failing if *not* run as `root`.
113
97
114
98
### Using `act` to run GH Actions locally
115
-
116
99
If you develop on macos but want to ensure code builds and tests pass on linux while making changes,
117
100
you can use the [act](https://github.com/nektos/act) tool to run the Github Actions Workflows on
118
101
the test matrix.
119
102
120
103
Just install `act` (`brew install act` on macOS) (previously install docker if you don't have it already,
121
-
and make sure the daemon is running) then run `act push`. You can test a subset of the rust
104
+
and make sure the daemon is running) then run `act push`. You can test a subset of the rust
122
105
and os versions of the matrix with something like `act push --matrix os:ubuntu-latest`
123
106
124
107
## Enter the matrix
125
-
126
108
If you want to test locally as much of the test matrix as possible (different OS and
127
109
versions of rust), that you can use `make matrix`. On macos, if you have `act`
128
110
installed, it will use it to run the linux part of the matrix.
129
111
130
112
### Macos: clang detection and header file finding
131
-
132
113
Newer versions of `bindgen` have improved the detection of `clang` and hence macos header files.
133
114
If you also have llvm/clang installed directly or via `brew` this may cause the build to fail saying it
134
115
cannot find `libproc.h`. This can be fixed by setting `CLANG_PATH="/usr/bin/clang"` so that `bindgen`
135
116
detects the Xcode version and hence can fidn the correct header files.
136
117
137
118
# Other docs
138
-
139
119
*[Reference docs](doc/References.md) used to build and document libproc-rs
140
120
* Details on methods available in different [macOS versions](doc/MacosVersions.md)
141
121
142
122
# LICENSE
143
-
144
123
This code is licensed under MIT license (see LICENCE).
0 commit comments