@@ -75,6 +75,7 @@ pkg_files(
7575
7676cc_shared_library (
7777 name = "AVO" ,
78+ visibility = ["//visibility:public" ],
7879 deps = ["//src:AVO" ],
7980)
8081
@@ -101,7 +102,7 @@ cat << 'EOF' > $@
101102 }
102103 },
103104 "cps_path": "@prefix@/lib/cps/AVO",
104- "cps_version": "0.13.0 ",
105+ "cps_version": "0.14.1 ",
105106 "default_components": ["AVO"],
106107 "description": "Reciprocal Collision Avoidance with Acceleration-Velocity Obstacles",
107108 "license": "Apache-2.0",
114115""" ,
115116)
116117
118+ genrule (
119+ name = "avo_release_cps" ,
120+ outs = ["AVO@release.cps" ],
121+ cmd = select ({
122+ "@platforms//os:macos" : """
123+ cat << 'EOF' > $@
124+ {
125+ "components":
126+ {
127+ "AVO":
128+ {
129+ "location": "@prefix@/lib/libAVO.dylib"
130+ }
131+ },
132+ "configuration": "Release",
133+ "name": "AVO"
134+ }
135+ EOF
136+ """ ,
137+ "@platforms//os:windows" : """
138+ cat << 'EOF' > $@
139+ {
140+ "components":
141+ {
142+ "AVO":
143+ {
144+ "location": "@prefix@/lib/AVO.dll"
145+ }
146+ },
147+ "configuration": "Release",
148+ "name": "AVO"
149+ }
150+ EOF
151+ """ ,
152+ "//conditions:default" : """
153+ cat << 'EOF' > $@
154+ {
155+ "components":
156+ {
157+ "AVO":
158+ {
159+ "location": "@prefix@/lib/libAVO.so"
160+ }
161+ },
162+ "configuration": "Release",
163+ "name": "AVO"
164+ }
165+ EOF
166+ """ ,
167+ }),
168+ )
169+
117170pkg_files (
118171 name = "cps" ,
119- srcs = ["AVO.cps" ],
172+ srcs = [
173+ "AVO.cps" ,
174+ "AVO@release.cps" ,
175+ ],
120176 attributes = pkg_attributes (mode = "0644" ),
121177 prefix = "usr/lib/cps/AVO" ,
122178)
@@ -197,11 +253,13 @@ pkg_tar(
197253
198254pkg_deb (
199255 name = "deb" ,
200- architecture = select ({
201- "@platforms//cpu:arm" : "amd64" ,
202- "@platforms//os:macos" : "arm64" ,
203- "//conditions:default" : "all" ,
204- }),
256+ architecture = select (
257+ {
258+ "@platforms//cpu:aarch64" : "arm64" ,
259+ "@platforms//cpu:x86_64" : "amd64" ,
260+ },
261+ no_match_error = "Unsupported CPU for //:deb. Supported CPUs: aarch64, x86_64." ,
262+ ),
205263 data = ":tar" ,
206264 depends = [
207265 "libc6" ,
@@ -215,6 +273,7 @@ pkg_deb(
215273 package = "avo" ,
216274 priority = "optional" ,
217275 section = "contrib/libdevel" ,
276+ target_compatible_with = ["@platforms//os:linux" ],
218277 triggers = "triggers" ,
219278 version = "1.0.1" ,
220279)
0 commit comments