Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Package not found になってしまいます #303

Open
Yuchie opened this issue Jan 10, 2016 · 10 comments
Open

Package not found になってしまいます #303

Yuchie opened this issue Jan 10, 2016 · 10 comments

Comments

@Yuchie
Copy link

Yuchie commented Jan 10, 2016

岡田先生 夜分遅くに失礼します。
03150289の中山です。
GCの課題を行おうと思いまして、変更したものをcatkin buildしてrosrunしたらpackageが存在しないと言われてしまいました。
20151007の課題を復習しようとした時も結局pacage beginner_tutorials not found となってしまったので根本的にどこかが変になってしまったと思うのですが全くわかりません。
ちなみにsource ~/2015-soft3/devel/setup.bashはしてあります。

mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202/src$ catkin build 
----------------------------------------------------------------------------
Profile:                     default
Extending:          [cached] /home/mech-user/catkin_ws/devel:/opt/ros/indigo
Workspace:                   /home/mech-user/work/win15/2015-soft3
Source Space:       [exists] /home/mech-user/work/win15/2015-soft3/src
Build Space:        [exists] /home/mech-user/work/win15/2015-soft3/build
Devel Space:        [exists] /home/mech-user/work/win15/2015-soft3/devel
Install Space:     [missing] /home/mech-user/work/win15/2015-soft3/install
DESTDIR:                     None
----------------------------------------------------------------------------
Isolate Develspaces:         False
Install Packages:            False
Isolate Installs:            False
----------------------------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
----------------------------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
----------------------------------------------------------------------------
Workspace configuration appears valid.
---------------------------------------------------------------------------- 
Found '1' packages in 0.0 seconds. 
Starting ==> roseus_tutorials                                                   
Finished <== roseus_tutorials [ 0.2 seconds ]                                   
[build] Finished.                                                               
[build] Runtime: 0.2 seconds 
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202/src$ rosrun enshu_20141202 GCTest
[rospack] Error: package 'enshu_20141202' not found
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202/src$ rosrun enshu_20151202 GCTest
[rospack] Error: package 'enshu_20151202' not found
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202/src$ echo $ROS_PACKAGE_PATH
/home/mech-user/work/win15/2015-soft3/src/roseus_tutorials:/home/mech-user/catkin_ws/src/kobuki:/home/mech-user/catkin_ws/src/robot-programming/turtleboteus:/home/mech-user/catkin_ws/src/robot-programming/dynamixel_7dof_arm:/home/mech-user/catkin_ws/src/testtest:/home/mech-user/catkin_ws/src/robot-programming/dxl_armed_turtlebot:/home/mech-user/catkin_ws/src/robot-programming/daisya_euslisp_tutorials:/home/mech-user/catkin_ws/src/roseus_tutorials:/opt/ros/indigo/share:/opt/ros/indigo/stacks

よろしければご教示ください。

中山

@k-okada
Copy link
Owner

k-okada commented Jan 11, 2016

おそくなりました.

[rospack] Error: package 'enshu_20141202' not found

が問題かな.
WORKSPACEのルートを~/work/win15/2015-soft3/20151202/src/enshu_20151202/においているか,
~/work/win15/2015-soft3/ においているか,どっちかなんだけど,
(WORKSPACEに対して,WORKSPACE/src, WORKSPACE/devel, WORKSPACE/buildができる)

上のログを見ると,~/work/win15/2015-soft3/ においてあるように見えるのですが,そこでcatkin buildしたら,enshu_20151202 が見つかっていないので,そこが問題に見えます.何が悪いかわからないけど,どこかにCATKIN_IGNOREとかのファイルがないだろうか,このファイルがあるとそれ以降のディレクトリを見てくれなくなります.可能性があるのは,~/work/win15/2015-soft3/20151202/CATKIN_IGNOREとかないだろうか.

現状``/work/win15/2015-soft3/にWORKSPACEがあるので,ちょっときたなくなるけど, /work/win15/2015-soft3/20151202` または,`~/work/win15/2015-soft3/20151202/src/enshu_20151202/`にWORKSPACEのルートとしてもよいです.その場合は
そのディレクトトリで`catkin init` してから`catkin build` すると`enshu_20151202`がコンパイルされると思います.後者にしたほうが他のディレクトリをコンパイルしないので,余計なトラブルはないかもしれないです.

@Yuchie
Copy link
Author

Yuchie commented Jan 11, 2016

今作業しているディレクトリでcatkin initしてからcatkin buildしたのですがやはり見つからないとなってしまいます。
WORKSPACEは確かに~/work/win15/2015-soft3/においていると思います。
CATKIN_IGNOREファイルも無いみたいなので他に可能性がありそうなことは無いでしょうか。

mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$ catkin init
 Catkin workspace `/home/mech-user/work/win15/2015-soft3` is already initialized. No action taken.
----------------------------------------------------------------------------
Profile:                     default
Extending:          [cached] /home/mech-user/catkin_ws/devel:/opt/ros/indigo
Workspace:                   /home/mech-user/work/win15/2015-soft3
Source Space:       [exists] /home/mech-user/work/win15/2015-soft3/src
Build Space:        [exists] /home/mech-user/work/win15/2015-soft3/build
Devel Space:        [exists] /home/mech-user/work/win15/2015-soft3/devel
Install Space:     [missing] /home/mech-user/work/win15/2015-soft3/install
DESTDIR:                     None
----------------------------------------------------------------------------
Isolate Develspaces:         False
Install Packages:            False
Isolate Installs:            False
----------------------------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
----------------------------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
----------------------------------------------------------------------------
Workspace configuration appears valid.
----------------------------------------------------------------------------
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$  catkin build
----------------------------------------------------------------------------
Profile:                     default
Extending:          [cached] /home/mech-user/catkin_ws/devel:/opt/ros/indigo
Workspace:                   /home/mech-user/work/win15/2015-soft3
Source Space:       [exists] /home/mech-user/work/win15/2015-soft3/src
Build Space:        [exists] /home/mech-user/work/win15/2015-soft3/build
Devel Space:        [exists] /home/mech-user/work/win15/2015-soft3/devel
Install Space:     [missing] /home/mech-user/work/win15/2015-soft3/install
DESTDIR:                     None
----------------------------------------------------------------------------
Isolate Develspaces:         False
Install Packages:            False
Isolate Installs:            False
----------------------------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
----------------------------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
----------------------------------------------------------------------------
Workspace configuration appears valid.
---------------------------------------------------------------------------- 
Found '1' packages in 0.0 seconds. 
Starting ==> roseus_tutorials                                                   
Finished <== roseus_tutorials [ 0.2 seconds ]                                   
[build] Finished.                                                               
[build] Runtime: 0.3 seconds 
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$ rosrun enshu_20151202 GCTest.cpp
[rospack] Error: package 'enshu_20151202' not found
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$ find /home/mech-user/work/win15/2015-soft3/ -name CATKIN_IGNORE
/home/mech-user/work/win15/2015-soft3/20151104/build/enshu_20151104/CATKIN_IGNORE

@Yuchie
Copy link
Author

Yuchie commented Jan 11, 2016

ちなみにroscd beginner_tutorialsも
roscd: No such package/stack 'beginner_tutorials'
とエラーが出てしまいます。

@k-okada
Copy link
Owner

k-okada commented Jan 12, 2016

なるほど.

~/work/win15/2015-soft3/20151202/src/enshu_20151202$ catkin init -w .

としてから同じ場所でcatkin buildするとどうなるでしょうか.

@Yuchie
Copy link
Author

Yuchie commented Jan 12, 2016

mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$ catkin init -w .
Initializing catkin workspace in `.`.
--------------------------------------------------------------------------------
Profile:                     default
Extending:             [env] /home/mech-user/work/win15/2015-soft3/devel:/home/mech-user/catkin_ws/devel:/opt/ros/indigo
Workspace:                   /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202
Source Space:       [exists] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/src
Build Space:       [missing] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/build
Devel Space:       [missing] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/devel
Install Space:     [missing] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/install
DESTDIR:                     None
--------------------------------------------------------------------------------
Isolate Develspaces:         False
Install Packages:            False
Isolate Installs:            False
--------------------------------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
--------------------------------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
--------------------------------------------------------------------------------
Workspace configuration appears valid.
--------------------------------------------------------------------------------
mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$ catkin build
----------------------------------------------------------------------------------------------
Profile:                     default
Extending:             [env] /home/mech-user/work/win15/2015-soft3/devel:/home/mech-user/catkin_ws/devel:/opt/ros/indigo
Workspace:                   /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202
Source Space:       [exists] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/src
Build Space:        [exists] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/build
Devel Space:        [exists] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/devel
Install Space:     [missing] /home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/install
DESTDIR:                     None
----------------------------------------------------------------------------------------------
Isolate Develspaces:         False
Install Packages:            False
Isolate Installs:            False
----------------------------------------------------------------------------------------------
Additional CMake Args:       None
Additional Make Args:        None
Additional catkin Make Args: None
Internal Make Job Server:    True
----------------------------------------------------------------------------------------------
Whitelisted Packages:        None
Blacklisted Packages:        None
----------------------------------------------------------------------------------------------
Workspace configuration appears valid.
---------------------------------------------------------------------------------------------- 
[build] Runtime: 0.0 seconds 
No packages were found in the source space '/home/mech-user/work/win15/2015-soft3/20151202/src/enshu_20151202/src'

となりました。やはりpackageがないと表示されています。

@k-okada
Copy link
Owner

k-okada commented Jan 12, 2016

cd ~/work/win15/2015-soft3/20151202/src/enshu_20151202
find src

するとどうなるのかな.

@Yuchie
Copy link
Author

Yuchie commented Jan 12, 2016

mech-user@test1-pc:~/work/win15/2015-soft3/20151202/src/enshu_20151202$ find src
src
src/Mutator.class
src/GCTest
src/GCTest.class
src/GCTest.gc.log
src/GCTest.incgc.log
src/GCTest.java
src/Sort.class
src/GCTest.cpp

と、なります。

@k-okada
Copy link
Owner

k-okada commented Jan 12, 2016

あ,ワークスペースをまちがいていたかもしれないです.

cd mech-user@test1-pc:~/work/win15/2015-soft3/20151202/
rm -fr src/enshu_20151202/.catkin*
catkin init -w .
catkin build

でしょうか.

@Yuchie
Copy link
Author

Yuchie commented Jan 12, 2016

出来ました!!
ありがとうございます。

workspaceを20151202にしたということでしょうか?
他のディレクトリで行う場合はまたそこをワークスペースにすれば良いということですか?

@k-okada
Copy link
Owner

k-okada commented Jan 26, 2016

workspaceを20151202にしたということでしょうか?

はいそうですね.

他のディレクトリで行う場合はまたそこをワークスペースにすれば良いということですか?

全てのディレクトリをまとめて一つのワークスペースにするか,それぞれのディレクトリでワークスペースにするか
方針を一つにして進めていけばいいと思います.今回は両方のルールが混ざっていてうまく行かなかったということか
ともいます.

◉ Kei Okada

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants