-
Notifications
You must be signed in to change notification settings - Fork 438
build: Install static lib #1948
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
build: Install static lib #1948
Conversation
This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Update: 2020-07-24 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
bbadd02 to
6a23d55
Compare
This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Update: 2020-07-24 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
cmake/iotjs.cmake
Outdated
| ${EXTERNAL_LIBS} | ||
| ) | ||
|
|
||
| target_link_libraries(${TARGET_STATIC_IOTJS} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This isn't necessary, the library will already be linked by the previous link_libraries call, since TARGET_LIB_IOTJS and TARGET_STATIC_IOTJS are just an alias for the same libiotjs target.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok, I just verified
cmake/iotjs.cmake
Outdated
| # Configure the libiotjs | ||
| set(TARGET_LIB_IOTJS libiotjs) | ||
| # Configure the libiotjs.a | ||
| set(TARGET_STATIC_IOTJS libiotjs) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't tnink it's necessary to add another alias.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's not anymore
cmake/iotjs.cmake
Outdated
| RUNTIME DESTINATION "${INSTALL_PREFIX}/bin" | ||
| LIBRARY DESTINATION "${INSTALL_PREFIX}/lib" | ||
| PUBLIC_HEADER DESTINATION "${INSTALL_PREFIX}/include/iotjs") | ||
| install(TARGETS ${TARGET_LIB_IOTJS} DESTINATION ${LIB_INSTALL_DIR}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The install command can take multiple target arguments, I'd suggest to not duplicate the calls. The install call on line 588 could be modified to be install(TARGETS ${TARGET_IOTJS} ${TARGET_LIB_IOTJS} ..., and then the calls on line 592 and 594 could be removed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes you're right, I am updating my patch and will update the other one that use destdir
This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Update: 2020-07-24 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Update: 2020-07-24 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
Add extra install step for installing lib along headers (Fixes: jerryscript-project#1896). Also remove headers, lib when installing executable. This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Relate-to: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Last-Update: 2020-10-15 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
6a23d55 to
2b7a1cd
Compare
Add extra install step for installing lib along headers (Fixes: jerryscript-project#1896). Also remove headers, lib when installing executable. This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Relate-to: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Last-Update: 2020-10-15 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
2b7a1cd to
8abaed1
Compare
installing the static lib will also install headers (Fixes: jerryscript-project#1896). This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Relate-to: jerryscript-project#1896 Last-Update: 2020-10-15 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
8abaed1 to
1855b93
Compare
installing the static lib will also install headers (Fixes: jerryscript-project#1896). This is useful for debian's iotjs-dev package Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Relate-to: jerryscript-project#1896 Last-Update: 2020-10-15 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
1855b93 to
2e56e9b
Compare
installing the static lib will also install headers (Fixes: jerryscript-project#1896). This is useful for debian's iotjs-dev package The extra archive rule is needed to prevent this error: install TARGETS given no ARCHIVE DESTINATION for static library target Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4 Forwarded: jerryscript-project#1948 Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master Bug: jerryscript-project#1945 Bug-Debian: https://bugs.debian.org/957364 Relate-to: jerryscript-project#1896 Last-Update: 2020-10-16 IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net
2e56e9b to
b13fa73
Compare
|
review welcome cc: @galpeter |
|
This change is released in: |
|
Please review meanwhile this change is in debian's testing branch: https://tracker.debian.org/pkg/iotjs [2020-10-26] iotjs 1.0+715-1 MIGRATED to testing (Debian testing watch) cc: @akosthekiss, @dbatyai, @zherczeg |
akosthekiss
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM in general but may be blocking on #1923
|
Thanks @akosthekiss , |
|
Hi I plan to update iotjs in Debian, On #1948 (review) I need 2 approvals to merge it, it's only a few lines to review: |
zherczeg
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
|
Thanks @zherczeg Anyone for an other approval please ? Cc: @LaszloLango , @ILyoan, @hs0225 |
LaszloLango
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This is useful for debian's iotjs-dev package
Change-Id: Ib9f6cb50631f4cdfeb308108f91ed28e7d204dc4
Forwarded: https://github.com/jerryscript-project/iotjs/pull/rzr
Origin: https://github.com/TizenTeam/iotjs/tree/sandbox/rzr/cmake/lib/review/master
Bug: #1945
Bug-Debian: https://bugs.debian.org/957364
Update: 2020-07-24
IoT.js-DCO-1.0-Signed-off-by: Philippe Coval rzr@users.sf.net