mirror of
https://github.com/lief-project/LIEF
synced 2026-06-08 15:30:44 +00:00
Switch the bindings to nanobind (and update the CI)
This commit is contained in:
@@ -13,12 +13,15 @@
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
#include "pyPlatform.hpp"
|
||||
#include "platforms/pyPlatform.hpp"
|
||||
#include "LIEF/platforms.hpp"
|
||||
#include "enums_wrapper.hpp"
|
||||
#include "pyLIEF.hpp"
|
||||
#include "platforms/android/pyAndroid.hpp"
|
||||
|
||||
namespace LIEF {
|
||||
namespace LIEF::py {
|
||||
|
||||
void init_python_platforms(py::module& m) {
|
||||
void init_platforms(nb::module_& m) {
|
||||
LIEF::enum_<PLATFORMS>(m, "PLATFORMS")
|
||||
.value("UNKNOWN", PLATFORMS::UNKNOWN)
|
||||
.value("LINUX", PLATFORMS::LINUX)
|
||||
@@ -28,8 +31,9 @@ void init_python_platforms(py::module& m) {
|
||||
.value("OSX", PLATFORMS::OSX);
|
||||
|
||||
m.def("current_platform", ¤t_platform,
|
||||
"Return the current plaform (Linux, Windows, ...) as a :attr:`lief.PLATFORMS` enum");
|
||||
"Return the current plaform (Linux, Windows, ...) as a :attr:`lief.PLATFORMS` enum"_doc);
|
||||
|
||||
LIEF::Android::py::init_module(m);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user