Skip to content

Commit 7176607

Browse files
committed
try fix for build command to find libmongocrypt
1 parent 46f7fb5 commit 7176607

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

internal/test/compilecheck/compile_check_test.go

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -133,12 +133,12 @@ func TestCompileCheck(t *testing.T) {
133133

134134
require.Equal(t, 0, exitCode, "dynamic linking build failed: %s", output)
135135

136-
// Build with tags (install libmongocrypt and gssapi headers).
137-
// Use the driver's install-libmongocrypt.sh script which is mounted at /driver.
136+
// Build with tags (install gssapi headers, use pre-built libmongocrypt from host).
137+
// libmongocrypt is installed on the host via "task install-libmongocrypt" and
138+
// mounted at /driver/install.
138139
installCmds := [][]string{
139140
{"apt-get", "update"},
140-
{"apt-get", "install", "-y", "libkrb5-dev", "cmake", "libssl-dev", "git", "pkg-config"},
141-
{"bash", "/driver/etc/install-libmongocrypt.sh"},
141+
{"apt-get", "install", "-y", "libkrb5-dev", "pkg-config"},
142142
}
143143

144144
for _, cmd := range installCmds {
@@ -151,10 +151,11 @@ func TestCompileCheck(t *testing.T) {
151151
require.Equal(t, 0, exitCode, "install command %v failed: %s", cmd, output)
152152
}
153153

154-
// The install script creates an "install" directory in the current working directory (/app).
154+
// Use libmongocrypt from the mounted driver directory.
155155
exitCode, outputReader, err = container.Exec(context.Background(), []string{
156-
"sh", "-c", "PKG_CONFIG_PATH=/app/install/lib/pkgconfig " +
157-
"LD_LIBRARY_PATH=/app/install/lib " +
156+
"sh", "-c",
157+
"export PKG_CONFIG_PATH=/driver/install/lib/pkgconfig && " +
158+
"export LD_LIBRARY_PATH=/driver/install/lib && " +
158159
"go build -buildvcs=false -tags=cse,gssapi,mongointernal ./...",
159160
})
160161
require.NoError(t, err)

0 commit comments

Comments
 (0)