summaryrefslogtreecommitdiff
path: root/namosim.spec
blob: cda5fe2a12668ac0772d23133aa27705bd5ec863 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
%define ros_distro humble
%define RosPkgName namosim
%define src_version 0.0.4-2

Name:           ros-%{ros_distro}-%{RosPkgName}
Version:        0.0.4
Release:        1%{?dist}
Summary:        A navigation planner for Navigation Among Movable Obstacles (NAMO)
License:        MIT
URL:            https://github.com/Chroma-CITI/namosim/tree/humble
Source0:        %{RosPkgName}-%{src_version}.tar.gz

%global debug_package %{nil}
%global __os_install_post %(echo '%{__os_install_post}' | sed -e 's!/usr/lib[^[:space:]]*/brp-python-bytecompile[[:space:]].*$!!g')
%global __provides_exclude_from ^/opt/ros/%{ros_distro}/.*$
%global __requires_exclude_from ^/opt/ros/%{ros_distro}/.*$

BuildRequires:  ros-%{ros_distro}-geometry-msgs
BuildRequires:  ros-%{ros_distro}-grid-map
BuildRequires:  ros-%{ros_distro}-grid-map-msgs
BuildRequires:  ros-%{ros_distro}-rclpy
BuildRequires:  cairo-devel
BuildRequires:  opencv
# 上游 package.xml 里的 Debian 名/裸名 → openEuler 实名的归一化
# (check_existing_package.py --chroot openeuler-24.03_LTS_SP3-aarch64 实证):
#   black            → python3-black         (官方源 24.2.0)
#   python3-tk       → python3-tkinter       (官方源 3.11.6)
#   python3-skimage  → python3-scikit-image  (官方源 0.25.2)
BuildRequires:  python3-black
BuildRequires:  python3-tkinter
BuildRequires:  python3-scikit-image
BuildRequires:  python3-bidict
BuildRequires:  python3-cairosvg
BuildRequires:  python3-jsonpickle
BuildRequires:  python3-matplotlib
BuildRequires:  python3-numpy
BuildRequires:  python3-pandas
BuildRequires:  python3-pillow
BuildRequires:  python3-pre-commit
BuildRequires:  python3-pydantic
BuildRequires:  python3-pytest
BuildRequires:  python3-pytest-cov
BuildRequires:  python3-requests
BuildRequires:  python3-shapely
BuildRequires:  python3-typer
BuildRequires:  python3-typing-extensions
BuildRequires:  python3-devel
BuildRequires:  python3-setuptools
# jupyter-notebook 已按 waived_deps.txt 豁免:官方源与 COPR 均无 provider,
# 且源码树无任何 jupyter import(仅上游 requirements.txt 的开发环境用),
# 非本包构建/运行所需。

Requires:       ros-%{ros_distro}-ros-workspace
Requires:       ros-%{ros_distro}-ament-cmake
Requires:       ros-%{ros_distro}-geometry-msgs
Requires:       ros-%{ros_distro}-grid-map
Requires:       ros-%{ros_distro}-grid-map-msgs
Requires:       ros-%{ros_distro}-rclpy
Requires:       cairo-devel
Requires:       opencv
Requires:       python3-black
Requires:       python3-tkinter
Requires:       python3-scikit-image
Requires:       python3-bidict
Requires:       python3-cairosvg
Requires:       python3-jsonpickle
Requires:       python3-matplotlib
Requires:       python3-numpy
Requires:       python3-pandas
Requires:       python3-pillow
Requires:       python3-pre-commit
Requires:       python3-pydantic
Requires:       python3-pytest
Requires:       python3-pytest-cov
Requires:       python3-requests
Requires:       python3-shapely
Requires:       python3-typer
Requires:       python3-typing-extensions

Provides:       %{name}-devel = %{version}-%{release}
Provides:       %{name}-doc = %{version}-%{release}
Provides:       %{name}-runtime = %{version}-%{release}

%description
A navigation planner for Navigation Among Movable Obstacles (NAMO)

%prep
%autosetup -n %{RosPkgName}-%{src_version}

%build
[ -f /opt/ros/%{ros_distro}/setup.sh ] && source /opt/ros/%{ros_distro}/setup.sh || true
export PYTHONPATH=/opt/ros/%{ros_distro}/lib/python%{python3_version}/site-packages${PYTHONPATH:+:$PYTHONPATH}
export PKG_CONFIG_PATH=/opt/ros/%{ros_distro}/lib/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}
%{__python3} setup.py build

%install
[ -f /opt/ros/%{ros_distro}/setup.sh ] && source /opt/ros/%{ros_distro}/setup.sh || true
export PYTHONPATH=/opt/ros/%{ros_distro}/lib/python%{python3_version}/site-packages${PYTHONPATH:+:$PYTHONPATH}
export PKG_CONFIG_PATH=/opt/ros/%{ros_distro}/lib/pkgconfig${PKG_CONFIG_PATH:+:$PKG_CONFIG_PATH}
%{__python3} setup.py install --skip-build --root %{buildroot} \
    --prefix /opt/ros/%{ros_distro} \
    --install-lib /opt/ros/%{ros_distro}/lib/python%{python3_version}/site-packages \
    --single-version-externally-managed --record installed.txt

%files
/opt/ros/%{ros_distro}

%changelog
* Tue Sep 22 2026 ai-importer <ai-importer@openeuler.org> - 0.0.4-1
- Initial import (ROS batch)