-
Notifications
You must be signed in to change notification settings - Fork 304
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
HPCC-29432 rebase and fix issues dependency/package issues for 9.4.x #17806
HPCC-29432 rebase and fix issues dependency/package issues for 9.4.x #17806
Conversation
@GordonSmith I did a complete rework of this branch. Included some tweaks to the NLP plugin addition you did a few months ago in order to ensure extra files weren't getting added to each plugin package. |
@@ -185,7 +185,7 @@ jobs: | |||
run: | | |||
mkdir -p ${{ needs.preamble.outputs.folder_build }} | |||
echo "${{ secrets.SIGNING_SECRET }}" > ${{ needs.preamble.outputs.folder_build }}/private.key | |||
plugins=("CASSANDRAEMBED" "COUCHBASEEMBED" "ECLBLAS" "H3" "JAVAEMBED" "KAFKA" "MEMCACHED" "MONGODBEMBED" "MYSQLEMBED" "NLP" "REDIS" "REMBED" "SQLITE3EMBED" "SQS" "PLATFORM" "CLIENTTOOLS_ONLY") | |||
plugins=("COUCHBASEEMBED" "H3" "JAVAEMBED" "KAFKA" "MEMCACHED" "MONGODBEMBED" "MYSQLEMBED" "NLP" "REDIS" "REMBED" "SQLITE3EMBED" "SQS" "PLATFORM" "CLIENTTOOLS_ONLY") |
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.
Cassanda and ECLBlas are both included in the base platform package. This just removes the option of building a 'plugin' for them too and confusing users.
HPCC_ADD_SUBDIRECTORY (system/hrpc "NLP") | ||
HPCC_ADD_SUBDIRECTORY (system/mp "NLP") | ||
HPCC_ADD_SUBDIRECTORY (system/security/securesocket "NLP") | ||
HPCC_ADD_SUBDIRECTORY (system/security/zcrypt "NLP") |
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.
These line changes were made to keep compile times down when we are building plugins. Those directories weren't needed to create the other plugins. If it's an NLP package, they'll get included in the build. But I went through those directories and added guards on the install() functions so we don't add a bunch of libraries to NLP that are already in the base platform.
@@ -218,7 +218,7 @@ if(APPLE) | |||
HPCC_ADD_SUBDIRECTORY(package) | |||
endif(APPLE) | |||
|
|||
if (NOT CLIENTTOOLS_ONLY) | |||
if (PLATFORM) |
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 removes all the vcpkg include files from getting added to each plugin package.
@@ -9,6 +9,7 @@ option(DEVEL "Enable the building/inclusion of a Development component." OFF) | |||
option(CLIENTTOOLS_ONLY "Enable the building of Client Tools only." OFF) | |||
option(INCLUDE_PLUGINS "Enable the building of platform and all plugins for testing purposes" OFF) | |||
option(USE_CASSANDRA "Include the Cassandra plugin in the base package" ON) | |||
option(USE_ECLBLAS "Include the ECLBLAS plugin in the base package" ON) |
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.
eclblas was included in the base package already, so I made it work similar to cassandra so there's no confusion in the future.
@@ -70,6 +68,10 @@ if (USE_CASSANDRA) | |||
set(VCPKG_CASSANDRAEMBED "${VCPKG_INCLUDE}") | |||
endif() | |||
|
|||
if (USE_ECLBLAS) | |||
set(VCPKG_ECLBLAS "${VCPKG_INCLUDE}") | |||
endif() |
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 block was necessary for the vcpkg.json file to get interpreted correctly.
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.
Now that ECL Blas is not a plugin, it will need to be manually set to VCPKG_SUPRESS, similar to what we do for VCPKG_APR below
TARGETS deftype | ||
RUNTIME DESTINATION ${EXEC_DIR} | ||
LIBRARY DESTINATION ${LIB_DIR}) | ||
endif() |
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 block is a guard that I added to several of the subdirectories. All the plugins were adding extra files that weren't needed from these directories because of the additions to the if(PLUGIN) add_subdirectory() portion of the top level cmake when we added NLP.
This mimics the behavior we have in jlib already, and a few other directories we were building to support plugin development.
install( | ||
TARGETS couchbaseembed | ||
RUNTIME_DEPENDENCY_SET couchbaseembed_deps | ||
DESTINATION plugins) |
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.
CALC_DEPS was grabbing to much. It did a great job of including all the dependencies, unfortunately some of those dependencies are built into the platform by default. So this RUNTIME_DEPENDENCY_SET is a way to have more control over the process. Allows us to find dependencies of under vcpkg_installed, and the PRE_EXCLUDE_REGEXES will sort out any of the linked sonames so we don't even search for them, removing the chance of package conflicts.
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.
How does this handle the dependencies of dependencies issue? (or have you manually checked that list?)
endif() | ||
endif() | ||
HPCC_ADD_LIBRARY(eclblas SHARED ${SRCS}) | ||
install ( TARGETS eclblas RUNTIME DESTINATION ${EXEC_DIR} LIBRARY DESTINATION ${LIB_DIR} CALC_DEPS) # No need to put in plugins 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.
CALC_DEPS is fine here since eclblas is included in the platform. Fixed some indentation and swapped to USE_ECLBLAS since this isn't treated like a plugin.
Signed-off-by: Michael Gardner <[email protected]>
d600b5d
to
3c10138
Compare
DESTINATION plugins | ||
CALC_DEPS | ||
) | ||
if(WIN32 OR APPLE) |
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 haven't heard of this package file conflict being an issue on macs. I kept this logic exactly the same for any build other than linux.
@@ -70,6 +68,10 @@ if (USE_CASSANDRA) | |||
set(VCPKG_CASSANDRAEMBED "${VCPKG_INCLUDE}") | |||
endif() | |||
|
|||
if (USE_ECLBLAS) | |||
set(VCPKG_ECLBLAS "${VCPKG_INCLUDE}") | |||
endif() |
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.
Now that ECL Blas is not a plugin, it will need to be manually set to VCPKG_SUPRESS, similar to what we do for VCPKG_APR below
install( | ||
TARGETS couchbaseembed | ||
RUNTIME_DEPENDENCY_SET couchbaseembed_deps | ||
DESTINATION plugins) |
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.
How does this handle the dependencies of dependencies issue? (or have you manually checked that list?)
Type of change:
Checklist:
Smoketest:
Testing: