mirror of
https://github.com/hashcat/hashcat.git
synced 2024-11-21 23:58:07 +00:00
Generate folders for cached kernels for the binary distribution in runtime, too
This commit is contained in:
parent
79b1f96efe
commit
11bf28745a
2
.gitignore
vendored
2
.gitignore
vendored
@ -9,5 +9,3 @@ deps/*
|
||||
deps/**
|
||||
lib/*.a
|
||||
obj/*.o
|
||||
kernels/4098/*.llvmir
|
||||
kernels/4318/*.cubin
|
||||
|
@ -12352,22 +12352,19 @@ int main (int argc, char **argv)
|
||||
* cached kernel path depends on vendor_id which we don't know, so create it here
|
||||
*/
|
||||
|
||||
if (profile_dir != install_dir) // not a bug
|
||||
{
|
||||
int vendor_id_folder_size = strlen (profile_dir) + 1 + 7 + 1 + 10 + 1;
|
||||
int vendor_id_folder_size = strlen (profile_dir) + 1 + 7 + 1 + 10 + 1;
|
||||
|
||||
char *vendor_id_folder = (char *) mymalloc (vendor_id_folder_size);
|
||||
char *vendor_id_folder = (char *) mymalloc (vendor_id_folder_size);
|
||||
|
||||
snprintf (vendor_id_folder, vendor_id_folder_size - 1, "%s/kernels", profile_dir);
|
||||
snprintf (vendor_id_folder, vendor_id_folder_size - 1, "%s/kernels", profile_dir);
|
||||
|
||||
mkdir (vendor_id_folder, 0700);
|
||||
mkdir (vendor_id_folder, 0700);
|
||||
|
||||
snprintf (vendor_id_folder, vendor_id_folder_size - 1, "%s/kernels/%d", profile_dir, vendor_id);
|
||||
snprintf (vendor_id_folder, vendor_id_folder_size - 1, "%s/kernels/%d", profile_dir, vendor_id);
|
||||
|
||||
mkdir (vendor_id_folder, 0700);
|
||||
mkdir (vendor_id_folder, 0700);
|
||||
|
||||
myfree (vendor_id_folder);
|
||||
}
|
||||
myfree (vendor_id_folder);
|
||||
|
||||
/**
|
||||
* devices
|
||||
|
@ -11,7 +11,7 @@ export OUT=$HOME/xy/oclHashcat-2.01
|
||||
rm -rf $OUT
|
||||
rm -rf $OUT.7z
|
||||
|
||||
mkdir -p $OUT $OUT/kernels $OUT/kernels/4098 $OUT/kernels/4318
|
||||
mkdir -p $OUT
|
||||
|
||||
cp $IN/oclHashcat??.exe $OUT/
|
||||
cp $IN/oclHashcat??.bin $OUT/
|
||||
@ -42,9 +42,6 @@ unix2dos $OUT/docs/*
|
||||
unix2dos $OUT/example*.cmd
|
||||
|
||||
chmod 700 $OUT
|
||||
chmod 700 $OUT/kernels
|
||||
chmod 700 $OUT/kernels/4098
|
||||
chmod 700 $OUT/kernels/4318
|
||||
chmod 700 $OUT/rules
|
||||
chmod 600 $OUT/rules/*
|
||||
chmod 700 $OUT/docs
|
||||
|
Loading…
Reference in New Issue
Block a user