Skip to content

Commit

Permalink
Merge pull request #1312 from messense/freebsd-arm
Browse files Browse the repository at this point in the history
Add armv6 and armv7 target support for FreeBSD
  • Loading branch information
messense authored Nov 30, 2022
2 parents efbb08d + 1cdb7e1 commit b85ffd5
Show file tree
Hide file tree
Showing 4 changed files with 1,125 additions and 0 deletions.
2 changes: 2 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
* Fix build error when required features of bin target isn't enabled in [#1299](https://github.com/PyO3/maturin/pull/1299)
* Fix wrong platform tag when building in i386 docker container on x86_64 host in [#1301](https://github.com/PyO3/maturin/pull/1301)
* Fix wrong platform tag when building in armv7 docker container on aarch64 host in [#1303](https://github.com/PyO3/maturin/pull/1303)
* Add Solaris operating system support in [#1310](https://github.com/PyO3/maturin/pull/1310)
* Add armv6 and armv7 target support for FreeBSD in [#1312](https://github.com/PyO3/maturin/pull/1312)

## [0.14.2] - 2022-11-24

Expand Down
150 changes: 150 additions & 0 deletions src/python_interpreter/sysconfig-freebsd.json
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,156 @@
"ext_suffix": ".cpython-310.so",
"abi_tag": "310",
"pointer_width": 64
},
{
"major": 3,
"minor": 11,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-311.so",
"abi_tag": "311",
"pointer_width": 64
}
],
"i686": [
{
"major": 3,
"minor": 7,
"abiflags": "m",
"interpreter": "cpython",
"ext_suffix": ".so",
"abi_tag": "37m",
"pointer_width": 64
},
{
"major": 3,
"minor": 8,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-38.so",
"abi_tag": "38",
"pointer_width": 64
},
{
"major": 3,
"minor": 9,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-39.so",
"abi_tag": "39",
"pointer_width": 64
},
{
"major": 3,
"minor": 10,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-310.so",
"abi_tag": "310",
"pointer_width": 64
},
{
"major": 3,
"minor": 11,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-311.so",
"abi_tag": "311",
"pointer_width": 64
}
],
"aarch64": [
{
"major": 3,
"minor": 7,
"abiflags": "m",
"interpreter": "cpython",
"ext_suffix": ".so",
"abi_tag": "37m",
"pointer_width": 64
},
{
"major": 3,
"minor": 8,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-38.so",
"abi_tag": "38",
"pointer_width": 64
},
{
"major": 3,
"minor": 9,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-39.so",
"abi_tag": "39",
"pointer_width": 64
},
{
"major": 3,
"minor": 10,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-310.so",
"abi_tag": "310",
"pointer_width": 64
},
{
"major": 3,
"minor": 11,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-311.so",
"abi_tag": "311",
"pointer_width": 64
}
],
"armv7l": [
{
"major": 3,
"minor": 7,
"abiflags": "m",
"interpreter": "cpython",
"ext_suffix": ".so",
"abi_tag": "37m",
"pointer_width": 64
},
{
"major": 3,
"minor": 8,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-38.so",
"abi_tag": "38",
"pointer_width": 64
},
{
"major": 3,
"minor": 9,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-39.so",
"abi_tag": "39",
"pointer_width": 64
},
{
"major": 3,
"minor": 10,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-310.so",
"abi_tag": "310",
"pointer_width": 64
},
{
"major": 3,
"minor": 11,
"abiflags": "",
"interpreter": "cpython",
"ext_suffix": ".cpython-311.so",
"abi_tag": "311",
"pointer_width": 64
}
]
}
5 changes: 5 additions & 0 deletions src/target.rs
Original file line number Diff line number Diff line change
Expand Up @@ -120,6 +120,8 @@ fn get_supported_architectures(os: &Os) -> Vec<Arch> {
Os::NetBsd => vec![Arch::Aarch64, Arch::X86, Arch::X86_64],
Os::FreeBsd => vec![
Arch::Aarch64,
Arch::Armv6L,
Arch::Armv7L,
Arch::Powerpc64,
Arch::Powerpc64Le,
Arch::X86,
Expand Down Expand Up @@ -236,6 +238,8 @@ impl Target {
(Os::FreeBsd, Arch::X86)
| (Os::FreeBsd, Arch::X86_64)
| (Os::FreeBsd, Arch::Aarch64)
| (Os::FreeBsd, Arch::Armv6L)
| (Os::FreeBsd, Arch::Armv7L)
| (Os::FreeBsd, Arch::Powerpc64)
| (Os::FreeBsd, Arch::Powerpc64Le)
// NetBSD
Expand All @@ -251,6 +255,7 @@ impl Target {
Arch::X86_64 => "amd64",
Arch::X86 => "i386",
Arch::Aarch64 => "arm64",
Arch::Armv6L | Arch::Armv7L => "arm",
Arch::Powerpc64 => "powerpc64",
Arch::Powerpc64Le => "powerpc64le",
_ => panic!(
Expand Down
Loading

0 comments on commit b85ffd5

Please sign in to comment.