Migrate everything to upstream pip packages
This patch migrates all the Python packages I could find to the
packages provided by rules_python. It's possible that there are some
that I missed. In that case, the finder will have to migrate it on
their own.
A future patch will remove the remaining references to the
Debian-packaged Python packages in future patches. This patch here is
solely focused on migrating the existing users.
Signed-off-by: Philipp Schrader <philipp.schrader@gmail.com>
Change-Id: Ic7a8ba6110516aa2446ad2ad4e2495fab62d824c
diff --git a/y2020/control_loops/python/BUILD b/y2020/control_loops/python/BUILD
index 9886452..8a1f737 100644
--- a/y2020/control_loops/python/BUILD
+++ b/y2020/control_loops/python/BUILD
@@ -9,9 +9,9 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:drivetrain",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -25,9 +25,9 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:polydrivetrain",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -41,11 +41,11 @@
visibility = ["//visibility:public"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:controls",
"//frc971/control_loops/python:drivetrain",
"//frc971/control_loops/python:polydrivetrain",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -58,10 +58,10 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:angular_system",
"//frc971/control_loops/python:controls",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -74,10 +74,10 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:angular_system",
"//frc971/control_loops/python:controls",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -90,10 +90,10 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:angular_system",
"//frc971/control_loops/python:controls",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -106,10 +106,10 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
"//frc971/control_loops/python:angular_system",
"//frc971/control_loops/python:controls",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -121,7 +121,7 @@
target_compatible_with = ["@platforms//cpu:x86_64"],
deps = [
"//frc971/control_loops/python:controls",
- "@matplotlib_repo//:matplotlib3",
+ "@pip//matplotlib",
],
)
@@ -135,8 +135,8 @@
deps = [
":flywheel",
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
@@ -150,8 +150,8 @@
deps = [
":flywheel",
":python_init",
- "//external:python-gflags",
- "//external:python-glog",
+ "@pip//glog",
+ "@pip//python_gflags",
],
)
diff --git a/y2020/vision/sift/BUILD b/y2020/vision/sift/BUILD
index 195a82e..1920cce 100644
--- a/y2020/vision/sift/BUILD
+++ b/y2020/vision/sift/BUILD
@@ -259,7 +259,7 @@
target_compatible_with = ["@platforms//os:linux"],
deps = [
":sift_fbs_python",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
+ "@pip//opencv_python",
],
)
diff --git a/y2020/vision/tools/python_code/BUILD b/y2020/vision/tools/python_code/BUILD
index d259ba7..4da3191 100644
--- a/y2020/vision/tools/python_code/BUILD
+++ b/y2020/vision/tools/python_code/BUILD
@@ -2,9 +2,9 @@
name = "train_and_match",
srcs = ["train_and_match.py"],
deps = [
- "//external:python-glog",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
- "@python_repo//:scipy",
+ "@pip//glog",
+ "@pip//opencv_python",
+ "@pip//scipy",
],
)
@@ -15,9 +15,9 @@
],
deps = [
":train_and_match",
- "//external:python-glog",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
- "@python_repo//:scipy",
+ "@pip//glog",
+ "@pip//opencv_python",
+ "@pip//scipy",
],
)
@@ -28,7 +28,7 @@
],
deps = [
":define_training_data",
- "//external:python-glog",
+ "@pip//glog",
],
)
@@ -42,8 +42,8 @@
":camera_definition",
":define_training_data",
":train_and_match",
- "//external:python-glog",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
+ "@pip//glog",
+ "@pip//opencv_python",
],
)
@@ -76,10 +76,10 @@
deps = [
":camera_definition",
":target_definition",
- "//external:python-glog",
"//y2020/vision/sift:sift_fbs_python",
"@bazel_tools//tools/python/runfiles",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
+ "@pip//glog",
+ "@pip//opencv_python",
],
)
@@ -95,10 +95,10 @@
deps = [
":camera_definition",
":target_definition",
- "//external:python-glog",
"//y2020/vision/sift:sift_fbs_python",
"@bazel_tools//tools/python/runfiles",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
+ "@pip//glog",
+ "@pip//opencv_python",
],
)
@@ -149,10 +149,10 @@
target_compatible_with = ["@platforms//os:linux"],
deps = [
":load_sift_training",
- "//external:python-glog",
"//y2020/vision/sift:sift_fbs_python",
"@bazel_tools//tools/python/runfiles",
- "@opencv_contrib_nonfree_amd64//:python_opencv",
+ "@pip//glog",
+ "@pip//opencv_python",
],
)