@@ -267,50 +267,6 @@ partial class Build
267
267
true ) ;
268
268
} ) ;
269
269
270
- Target PublishLibdatadog => _ => _
271
- . Unlisted ( )
272
- . DependsOn ( PublishLibdatadogWindows )
273
- . DependsOn ( PublishLibdatadogLinux ) ;
274
-
275
- Target PublishLibdatadogWindows => _ => _
276
- . Unlisted ( )
277
- . OnlyWhenStatic ( ( ) => IsWin )
278
- . After ( CompileProfilerNativeSrc )
279
- . Executes ( ( ) =>
280
- {
281
- const string fileName = "datadog_profiling_ffi" ;
282
- foreach ( var architecture in ArchitecturesForPlatformForProfiler )
283
- {
284
- var sourceDir = ProfilerDeployDirectory / $ "win-{ architecture } ";
285
- var source = sourceDir / $ "{ fileName } .dll";
286
- var dest = MonitoringHomeDirectory / $ "win-{ architecture } ";
287
- CopyFileToDirectory ( source , dest , FileExistsPolicy . Overwrite ) ;
288
-
289
- source = sourceDir / $ "{ fileName } .pdb";
290
- dest = SymbolsDirectory / $ "win-{ architecture } " / Path . GetFileName ( source ) ;
291
- CopyFile ( source , dest , FileExistsPolicy . Overwrite ) ;
292
- }
293
- } ) ;
294
-
295
- Target PublishLibdatadogLinux => _ => _
296
- . Unlisted ( )
297
- . OnlyWhenStatic ( ( ) => IsLinux )
298
- . After ( CompileProfilerNativeSrc )
299
- . Executes ( ( ) =>
300
- {
301
- var ( arch , _) = GetUnixArchitectureAndExtension ( ) ;
302
- var sourceDir = ProfilerDeployDirectory / arch ;
303
- EnsureExistingDirectory ( MonitoringHomeDirectory / arch ) ;
304
-
305
- var files = new [ ] { "libdatadog_profiling.so" } ;
306
- foreach ( var file in files )
307
- {
308
- var source = sourceDir / file ;
309
- var dest = MonitoringHomeDirectory / arch / file ;
310
- CopyFile ( source , dest , FileExistsPolicy . Overwrite ) ;
311
- }
312
- } ) ;
313
-
314
270
Target ValidateNativeTracerGlibcCompatibility => _ => _
315
271
. Unlisted ( )
316
272
. OnlyWhenStatic ( ( ) => IsLinux )
@@ -320,7 +276,7 @@ partial class Build
320
276
. Executes ( ( ) =>
321
277
{
322
278
var ( arch , extension ) = GetUnixArchitectureAndExtension ( ) ;
323
- var dest = MonitoringHomeDirectory / arch / $ "{ NativeTracerProject . Name } .{ extension } ";
279
+ var files = new [ ] { $ "{ NativeTracerProject . Name } .{ extension } ", $ "libddwaf. { extension } " } ;
324
280
325
281
// If we need to increase this version on arm64 later, that is ok as long
326
282
// as it doesn't go above 2.23. Just update the version below. We must
@@ -332,7 +288,12 @@ partial class Build
332
288
? new Version ( 2 , 18 )
333
289
: new Version ( 2 , 17 ) ;
334
290
335
- ValidateNativeLibraryGlibcCompatibility ( dest , expectedGlibcVersion ) ;
291
+ foreach ( var file in files )
292
+ {
293
+ var dest = MonitoringHomeDirectory / arch / $ "{ file } ";
294
+
295
+ ValidateNativeLibraryGlibcCompatibility ( dest , expectedGlibcVersion ) ;
296
+ }
336
297
} ) ;
337
298
338
299
void ValidateNativeLibraryGlibcCompatibility ( AbsolutePath libraryPath , Version expectedGlibcVersion )
@@ -346,7 +307,7 @@ void ValidateNativeLibraryGlibcCompatibility(AbsolutePath libraryPath, Version e
346
307
{
347
308
throw new Exception ( $ "Alpine build of { filename } should not have glibc symbols in the binary, but found { glibcVersion } ") ;
348
309
}
349
- else if ( ! IsAlpine && glibcVersion != expectedGlibcVersion )
310
+ else if ( ! IsAlpine && glibcVersion > expectedGlibcVersion )
350
311
{
351
312
throw new Exception ( $ "{ filename } should have a minimum required glibc version of { expectedGlibcVersion } but has { glibcVersion } ") ;
352
313
}
0 commit comments