How to add zstd and lz4 algorithm to tar on MacOS? - macos

So my tar version on MacOS doesn't seem to support the zstd or lz4 algorithms, and I am unsure how to update tar or add support for it. My Ubuntu's tar version seems to have support for zstd.

Related

Downloading STAR on MAC OS Mojave

I am trying to download STAR for RNA seq. After I installed gcc 8.2, and inputting this command on terminal
make STARforMacStatic CXX=/Users/local/Cellar/gcc/8.3.0/bin/g++-8
It keeps responding
make: *** No rule to make target `STARforMacStatic'. Stop.
How do I get this work?
These days, you really don't need to be downloading and manually managing things like gcc or building STAR. Instead, install Bioconda (i.e., Miniconda + bioconda and conda-forge channels), then it's just a matter of
conda install star
If you use brew (like sugest README file), this path (CXX=/Users/local/Cellar/gcc/8.3.0/bin/g++-8).
Copy and paste command from README file:
$make STARforMacStatic CXX=/usr/local/Cellar/gcc/8.2.0/bin/g++-8
Path to brew files is /usr/local/Cellar. Mine:
alex#vosjod:/usr/local/Cellar$ ls -1
adns
aom
bash-completion
bashmarks
ctags
erlang
exiftool
ffmpeg
fontconfig
freetype
frei0r
fribidi
gdbm
gettext
git
gmp
gnupg
gnutls
go
icu4c
jpeg
...

How to solve the error when compile the hadoop2.7.3?

The software I used as following:
And I meet the error as following:
The system I used is Centos 7 and the JDK I used is 1.7.0_07. Anyone can help me to solve the problem?
You might be missing some of the libraries required to build hadoop. Do you have all this installed?
yum -y install wget gcc gcc-c++ autoconf automake libtool zlib-devel cmake openssl openssl-devel snappy snappy-devel bzip2 bzip2-devel protobuf protobuf-devel
If libraries are not the case, you can find this project useful. This is a bash script which builds hadoop from scratch. May be there you'll find a step you've missed:
https://github.com/hadoopfromscratch/hadoopfromscratch

Error while unzipping a file in shell script. - need PK compat. v5.1 (can do v4.6)

I'm using unzip test.zip in a Shell script. But while executing this line i get an error
Archive: test.zip
skipping: hello.pdf need PK compat. v5.1 (can do v4.6)
Even if i try to run this single command from the terminal in ubuntu it throws the same error need PK compat. v5.1 (can do v4.6)
Uninstalling and reinstalling unzip also didn't work. Alternately I had to install p7zip-full to unzip the test.zip file. How to fix this and use unzip in the shell script??
Use 7z from p7zip-full package in Debian:
$ 7z x test.zip
You can use p7zip to perform the required action.
Use brew to install it.
$ brew install p7zip
use this to unzip a file
$ 7z x file.zip
I think it is "normal" that info-zip's unzip6.0 can only work with ZIP Entries which use the 4.6 version. This describes the features needed to uncompress it. The latest addition in unzip 6.0 is bzip2, which is represented in version 4.6. The 5.1 version you get when you use the (AES) strong encryption feature.
You need to use alternative tools like the mentioned 7zip (or the commercial pkunzip) to unpack those files. When you can influence the creation process, then play around with the features you use and which not (i.e. do not ask for strong password encryption if you want to be compatible with legacy infozip tool).
And yes, this is somewhat unfortunate. And I think the unzip is ported to so many target platforms, that nobody wants to work on it anymore .)
Try installing 7z sudo apt-get install p7zip-full and then extract the file with it.
For example:
7z x datafile.zip -aoa -p$3CR37
Argument -p****** is the password.
-aoa allows extraction over any existing local files.
You need install 7z
Search the package
$ apt search p7zip
....
....
p7zip/focal,now 16.02+dfsg-7build1 amd64 [已安装]
7zr file archiver with high compression ratio
p7zip-full/focal 16.02+dfsg-7build1 amd64
7z and 7za file archivers with high compression ratio
...
You can see the p7zip-full/focal 16.02+dfsg-7build1 amd64 is the currect one
$ sudo apt install p7zip-full, now you can run 7z command,for help 7z --help
Decompress file with
7z x test.zip -p****
-p Switches doesn't have write if the file has no password

install error of CASAVA on Ubuntu 12.04LTS

I am trying to install CASAVA Bcl2Fastq 1.8.3 (developed for CentOS) on Ubuntu 12.04 LTS. However, I got an error message "No support for gzip compression" and the install failed. Luckily, I found a solution for this problem:
sudo ln -s /usr/lib/x86_64-linux-gnu/libpthread* /usr/lib
sudo ln -s /usr/lib/x86_64-linux-gnu/libz.so /usr/lib
But now I got another similar error "No support for bzip2 compression". I am wondering if I can do something similar to solve this error?
I finally solved this by linking the bzip2 library file in /usr/lib/x86_64-linux-gnu/ to /usr/lib:
sudo ln -s /usr/lib/x86_64-linux-gnu/libbz2* /usr/lib
But I am wondering why gcc cannot find the library files automatically, is it a problem of my Unbuntu installation or some incompatibility of the CASAVA Bcl2Fastq 1.8.3 software (because it was developed and tested on CentOS)?
For those returning to this issue - if you can't find any of the appropriate libbz2* files under /usr/lib/x86_64-linux-gnu/, try:
sudo apt-get install libbz2-dev libbz2

Imagemagick jpeg decode delegate missing with OS X Homebrew install

I recently converted from macports to homebrew and my previous macports Imagemagick install was working fine. I followed the homebrew instructions to chown /usr/local (somewhat apprehensively) and remove /usr/local/include and /usr/local/lib. When trying to work with any jpeg images, imagemagick chokes with:
no decode delegate for this image format
Here is a list of some relevant command output. As you can see, no jpeg/jpg delegate can be found.
convert -list configure =>
DELEGATES bzlib freetype png x11 xml zlib
identify -list configure => DELEGATES bzlib freetype png x11 xml zlib
However, jpeg lib was installed as part of the Imagemagick dependencies, so I'm not sure what's going on here.
brew list => imagemagick jasper jpeg libtiff little-cms nginx pcre
brew doctor => Your OS X is ripe for brewing. Any troubles you may be experiencing are likely purely psychosomatic.
identify --version => Version: ImageMagick 6.6.7-9 2011-04-06 Q16
Any ideas?
Andrei, your solution got me in the right direction.
but it was a
brew install --force jpeg
brew install --force imagemagick
that got it working for me.
I just ran into this issue myself. While investigating I noticed symlinks to the jpeg jib were missing from /usr/local/lib. Can take of this with the following; just be sure to refer to the jpeg lib version in use, at the time of this post I am using 8c:
ln -s /usr/local/Cellar/jpeg/8c/lib/libjpeg.8.dylib /usr/local/lib/libjpeg.8.dylib
ln -s /usr/local/Cellar/jpeg/8c/lib/libjpeg.a /usr/local/lib/libjpeg.a
Then force homebrew to reinstall imagemagick:
brew install --force imagemagick
Viola! Imagemagick will now show that a jpeg delegate is present.
Thanks for the direction pointed. My jpeg is also already in the delegate list, re-installing imagemagick doesn't work for me, but relinking jpeg does:
brew unlink jpeg
brew link jpeg
I had this problem and it turned out to be permissions.
sudo chown myuser:wheel /usr/local
then:
brew remove jpeg
brew remove imagemagick
brew install jpeg
brew install imagemagick
sorted it.
Word of warning though: I had MySQL sittting in /usr/local/ too, and I inadvertently messed up permissions for that, so if you've got anything else important in there, be careful :-)
Fixed that with:
sudo chown -R mysql:wheel /usr/local/mysql/data
Hope this helps someone!
9monkeys solution here plus restarting Terminal worked for me.

Resources