Skip to content

Commit

Permalink
Update populateClientLibsIn.fromProductNamed.ifAbsent..st
Browse files Browse the repository at this point in the history
  • Loading branch information
JupiterJones committed Jul 19, 2024
1 parent a8ae4b0 commit 1fc04f1
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
product management
populateClientLibsIn: productsDirPath fromProductNamed: productName ifAbsent: absentBlock
| productsDir productTreeDir clientLibDir libDir libNames readOnlyPermissions |
| productsDir productTreeDir clientLibDir libDir libNames readOnlyPermissions libExtensions |
productsDir := productsDirPath asFileReference.
productTreeDir := (self products at: productName ifAbsent: absentBlock)
asFileReference.
Expand All @@ -9,11 +9,12 @@ populateClientLibsIn: productsDirPath fromProductNamed: productName ifAbsent: ab
libDir := clientLibDir / productName / '64bit'.
libDir ensureCreateDirectory.
libNames := #('libgcirpc' 'libgcits' 'libkrb5' 'libssl').
libExtensions := #('so' 'dylib').
readOnlyPermissions := FileSystemPermission posixPermissions: 8r444.
(productTreeDir / 'lib') children
do: [ :each |
each extension = 'so'
ifTrue: [
(libExtensions detect: [ :libExt | libExt = each extension] ifNone: [ nil ])
ifNotNil: [ :libExtension |
libNames
do: [ :libName |
(each basename beginsWith: libName)
Expand All @@ -30,7 +31,7 @@ populateClientLibsIn: productsDirPath fromProductNamed: productName ifAbsent: ab
"if an alpha or beta is downloaded the product name will look
something like 370_rowanv3-Alpha1 and JfP will be looking
for a lilbgcits using that product name ... create a symbol link"
link := libDir / (libName , '-' , productName , '-64.so').
link := libDir / (libName , '-' , productName , '-64.', libExtension).
link basename ~= target basename
ifTrue: [
| cwd |
Expand Down

0 comments on commit 1fc04f1

Please sign in to comment.