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

include directoryの表記をソースファイルとpkg-configを使った場合で同じにする #842

Merged
merged 1 commit into from
Apr 3, 2016

Conversation

YoheiKakiuchi
Copy link
Contributor

#803
の変更にともなって、
ソースファイルでのinclude の表記とpkg-configを使った場合のincludeの表記が
同じになるように修正しました。

(io/iob.h -> hrpsys/io/iob.h,
xxx.hh -> hrpsys/idl/xxx.hh,
util/xxx.h -> hrpsys/util/xxx.h)

@YoheiKakiuchi YoheiKakiuchi changed the title include directoryno include directoryの表記をソースファイルとpkg-configを使った場合で同じにする Oct 3, 2015
@k-okada
Copy link
Contributor

k-okada commented Oct 3, 2015

Refer to this link for build results (access rights to CI server needed):
https://jenkins.jsk.imi.i.u-tokyo.ac.jp:8080/job/hrpsys-qnx/2384/

Build Log
last 10 lines

[...truncated 7560 lines...]
    at org.jenkinsci.plugins.ghprb.GhprbRepository.createCommitStatus(GhprbRepository.java:122)
    at org.jenkinsci.plugins.ghprb.GhprbBuilds.onCompleted(GhprbBuilds.java:118)
    at org.jenkinsci.plugins.ghprb.GhprbBuildListener.onCompleted(GhprbBuildListener.java:27)
    at org.jenkinsci.plugins.ghprb.GhprbBuildListener.onCompleted(GhprbBuildListener.java:12)
    at hudson.model.listeners.RunListener.fireCompleted(RunListener.java:201)
    at hudson.model.Run.execute(Run.java:1786)
    at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
    at hudson.model.ResourceController.execute(ResourceController.java:98)
    at hudson.model.Executor.run(Executor.java:408)

Test FAILed.

@k-okada
Copy link
Contributor

k-okada commented Oct 5, 2015

結構な変化なのでバージョン切りたいですが,この前で切って,この変更入れて切って,という感じでしょうか?作業中のものは
#839
#837
でしょうか.

@k-okada
Copy link
Contributor

k-okada commented Oct 6, 2015

コンパイル中にsymbolic link貼りまくるのは正解だろうか?
他にやりかたがあるかというと難しいけど、
libにかんしてはinclude/hrpsys->libとはるeusスタイルもあるきがする
Idlはどうだろうかコンパイル時に出力さきをかえるとか、インストール時に書き換えるとか、#include <$EXPORT_PATH/ion.h> みたいな感じとか

@k-okada
Copy link
Contributor

k-okada commented Oct 27, 2015

#867 で別実装をつくってみましたが,あまりかわらないかなぁ.

最終的にどういう風になるのがいいのかよくわかっていませんが,
1)ソースツリーは hrpsys-base/lib/io/iob.h に置かれている.
2)インストールするときは include/hrpsys/io/iob.hに置かれるようになる.
3)たのソース,たとえばec/hrpEC/hrpEC-common.cpp も,コンパイル時はhrpsys-base/ecにあるが,インストールするときはshare/hrpsys/src/ec/ に置かれる.ここに置かれたコードは,外部のプログラムが参照する可能性がある.なので,インストール後のhrpEC-common.cpp

@@ -1,5 +1,5 @@
 #include "hrpEC.h"
-#include "io/iob.h"
+#include "hrpsys/io/iob.h"

と変更する必要が有る

とすると,解法としては
A) そもそものソースツリーをhrpsys-base/include/hrpsys/io/iob.h とする
B) インストールしたファイルのヘッダファイルを書き直す #867
なんではないかともうけどどうなんだろうか.

普通はどうしているんですかね?

@fkanehiro
Copy link
Owner

A)のような気がするけれども、具体的にはどんな問題が起きているのでしたっけ?
外部のプログラムからインクルードファイルが見つからなくなったということ?

2015年10月27日 12:05 Kei Okada [email protected]:

#867 #867
で別実装をつくってみましたが,あまりかわらないかなぁ.

最終的にどういう風になるのがいいのかよくわかっていませんが,
1)ソースツリーは hrpsys-base/lib/io/iob.h に置かれている.
2)インストールするときは include/hrpsys/io/iob.hに置かれるようになる.
3)たのソース,たとえばec/hrpEC/hrpEC-common.cpp も,コンパイル時はhrpsys-base/ec
にあるが,インストールするときはshare/hrpsys/src/ec/
に置かれる.ここに置かれたコードは,外部のプログラムが参照する可能性がある.なので,インストール後のhrpEC-common.cppは

@@ -1,5 +1,5 @@
#include "hrpEC.h"
-#include "io/iob.h"
+#include "hrpsys/io/iob.h"

と変更する必要が有る

とすると,解法としては
A) そもそものソースツリーをhrpsys-base/include/hrpsys/io/iob.h とする
B) インストールしたファイルのヘッダファイルを書き直す #867
#867
なんではないかともうけどどうなんだろうか.

普通はどうしているんですかね?


Reply to this email directly or view it on GitHub
#842 (comment)
.

@k-okada
Copy link
Contributor

k-okada commented Mar 24, 2016

@YoheiKakiuchi could you create this PR with latest source tree?

 (io/iob.h -> hrpsys/io/iob.h,
  xxx.hh -> hrpsys/idl/xxx.hh,
  util/xxx.h -> hrpsys/util/xxx.h)
@k-okada
Copy link
Contributor

k-okada commented Apr 2, 2016

Refer to this link for build results (access rights to CI server needed):
https://jenkins.jsk.imi.i.u-tokyo.ac.jp:8080/job/hrpsys-qnx/2573/

Build Log
last 10 lines

[...truncated 8544 lines...]
    at org.jenkinsci.plugins.ghprb.GhprbRepository.createCommitStatus(GhprbRepository.java:122)
    at org.jenkinsci.plugins.ghprb.GhprbBuilds.onCompleted(GhprbBuilds.java:118)
    at org.jenkinsci.plugins.ghprb.GhprbBuildListener.onCompleted(GhprbBuildListener.java:27)
    at org.jenkinsci.plugins.ghprb.GhprbBuildListener.onCompleted(GhprbBuildListener.java:12)
    at hudson.model.listeners.RunListener.fireCompleted(RunListener.java:202)
    at hudson.model.Run.execute(Run.java:1783)
    at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:43)
    at hudson.model.ResourceController.execute(ResourceController.java:98)
    at hudson.model.Executor.run(Executor.java:410)

Test FAILed.

@YoheiKakiuchi
Copy link
Contributor Author

最新ソースからPRつくり直しました。

外部のプログラムからインクルードファイルが見つからなくなったということ?

そうです。外部のiobとリンクするためにRobotHardwareをソースツリー外でコンパイルするときがあります。
(これ自体は、iobのリンク先を変える方法が思いつくのですが、そうとう格闘した結果うまくいっていない状況です)
また、hrpsys-baseのソースツリー外で作るrtcと内部のrtcでインクルードが違ってしまうということがあります。

@fkanehiro fkanehiro merged commit d06269e into fkanehiro:master Apr 3, 2016
@YoheiKakiuchi YoheiKakiuchi deleted the fix_include_dir branch May 13, 2016 08:13
hikun5296 added a commit to hikun5296/hrpsys-base that referenced this pull request Oct 5, 2016
hikun5296 added a commit to hikun5296/hrpsys-base that referenced this pull request Apr 14, 2017
YoheiKakiuchi pushed a commit to YoheiKakiuchi/hrpsys-base that referenced this pull request Jun 6, 2018
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 12, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 12, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 14, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 14, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 14, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 14, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 21, 2019
pazeshun added a commit to pazeshun/rtmros_gazebo that referenced this pull request Nov 21, 2019
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

Successfully merging this pull request may close these issues.

3 participants