Hi everyone,
I'm trying to install Stacks v2.66 in MacOS Sonoma in a Mac Studio with an M2 chip. After doing configure and make, I got the following error related to omp_lock_t. Can someone help me with this? Thank you very much!
Making install in htslib
make[2]: Nothing to be done for `install-exec-am'.
make[2]: Nothing to be done for `install-data-am'.
depbase=`echo src/process_radtags.o | sed 's|[^/]*$|.deps/&|;s|\.o$||'`;\
g++ -std=gnu++11 -DHAVE_CONFIG_H -I. -I./htslib -g -O2 -MT src/process_radtags.o -MD -MP -MF $depbase.Tpo -c -o src/process_radtags.o src/process_radtags.cc &&\
mv -f $depbase.Tpo $depbase.Po
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:30:
In file included from src/input.h:34:
In file included from src/stacks.h:36:
src/utils.h:426:9: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(buf, "%d", i);
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:30:
In file included from src/input.h:34:
In file included from src/stacks.h:36:
src/utils.h:438:9: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(buf, "%ld", i);
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:30:
In file included from src/input.h:34:
In file included from src/stacks.h:36:
src/utils.h:450:9: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(buf, "%zu", i);
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:30:
In file included from src/input.h:34:
In file included from src/stacks.h:40:
src/DNASeq4.h:80:58: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
DNASeq4(DNASeq4&& other) noexcept : l_(other.l_), v_(move(other.v_)) {other.clear();}
^
std::
src/DNASeq4.h:86:63: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
DNASeq4& operator= (DNASeq4&& other) {l_ = other.l_; v_ = move(other.v_); other.clear(); return *this;}
^
std::
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:30:
In file included from src/input.h:34:
src/stacks.h:270:15: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
: seq(move(s)), name(move(n))
^
std::
src/stacks.h:270:30: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
: seq(move(s)), name(move(n))
^
std::
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:31:
In file included from src/kmers.h:36:
In file included from src/locus.h:34:
src/Alignment.h:59:41: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
AlnRead(Read&& r, Cigar&& c) : Read(move(r)), cigar(move(c)) {}
^
std::
src/Alignment.h:59:57: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
AlnRead(Read&& r, Cigar&& c) : Read(move(r)), cigar(move(c)) {}
^
std::
src/Alignment.h:223:25: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
return AlnRead(Read(move(seq), move(name)), move(cig));
^
std::
src/Alignment.h:223:36: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
return AlnRead(Read(move(seq), move(name)), move(cig));
^
std::
src/Alignment.h:223:49: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
return AlnRead(Read(move(seq), move(name)), move(cig));
^
std::
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:31:
In file included from src/kmers.h:36:
src/locus.h:180:40: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
SRead(Read&& r, size_t spl) : Read(move(r)), sample(spl) {}
^
std::
src/locus.h:186:49: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
SAlnRead(AlnRead&& r, size_t spl) : AlnRead(move(r)), sample(spl) {}
^
std::
src/locus.h:187:57: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
SAlnRead(Read&& r, Cigar&& c, size_t spl) : AlnRead(move(r), move(c)), sample(spl) {}
^
std::
src/locus.h:187:66: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
SAlnRead(Read&& r, Cigar&& c, size_t spl) : AlnRead(move(r), move(c)), sample(spl) {}
^
std::
src/locus.h:216:43: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
void add(SRead&& r) {reads_.push_back(move(r));}
^
std::
src/locus.h:217:49: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
void add_pe(SRead&& r) {pe_reads_.push_back(move(r));}
^
std::
src/locus.h:245:35: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
void ref(DNASeq4&& s) {ref_ = move(s);}
^
std::
src/locus.h:308:22: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
reads_.push_back(move(r));
^
std::
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:43:
In file included from src/clean.h:31:
In file included from src/kmers.h:37:
src/mstack.h:92:18: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, utags (move(o.utags))
^
std::
src/mstack.h:93:20: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, remtags (move(o.remtags))
^
std::
src/mstack.h:95:17: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, dist (move(o.dist))
^
std::
src/mstack.h:96:17: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, alns (move(o.alns))
^
std::
src/mstack.h:99:16: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, loc (move(o.loc))
^
std::
src/mstack.h:100:17: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, snps (move(o.snps))
^
std::
src/mstack.h:101:20: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, alleles (move(o.alleles))
^
std::
src/mstack.h:102:17: warning: unqualified call to 'std::move' [-Wunqualified-std-cast-call]
, gaps (move(o.gaps))
^
std::
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:48:
src/BustardI.h:72:5: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(s->id, "@%s:%s:%s:%s:%s#%s/%s",
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
In file included from src/process_radtags.cc:31:
In file included from src/process_radtags.h:48:
src/BustardI.h:101:5: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(s.id, "@%s:%s:%s:%s:%s#%s/%s",
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
src/process_radtags.cc:498:6: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(numstr, "%ldM...", i/1000000);
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
src/process_radtags.cc:743:5: error: unknown type name 'omp_lock_t'
omp_lock_t inpbuf_lock[num_worker_threads];
^
src/process_radtags.cc:744:5: error: unknown type name 'omp_lock_t'
omp_lock_t outbuf_lock[num_worker_threads];
^
src/process_radtags.cc:796:18: error: use of undeclared identifier 'omp_get_thread_num'
int thread_no = omp_get_thread_num();
^
src/process_radtags.cc:957:4: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(numstr, "%dM...", int(records_written/1000000));
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
src/process_radtags.cc:977:6: error: unknown type name 'omp_lock_t'
omp_lock_t &thread_inpbuf_lock = inpbuf_lock[thread_index];
^
src/process_radtags.cc:979:6: error: unknown type name 'omp_lock_t'
omp_lock_t &thread_outbuf_lock = outbuf_lock[thread_index];
^
src/process_radtags.cc:1191:6: warning: 'sprintf' is deprecated: This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead. [-Wdeprecated-declarations]
sprintf(numstr, "%ldM...", i/1000000);
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/stdio.h:180:1: note: 'sprintf' has been explicitly marked deprecated here
__deprecated_msg("This function is provided for compatibility reasons only. Due to security concerns inherent in the design of sprintf(3), it is highly recommended that you use snprintf(3) instead.")
^
/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/sys/cdefs.h:215:48: note: expanded from macro '__deprecated_msg'
#define __deprecated_msg(_msg) __attribute__((__deprecated__(_msg)))
^
src/process_radtags.cc:1340:5: error: unknown type name 'omp_lock_t'
omp_lock_t inpbuf_lock[num_worker_threads];
^
Hi, to install Stacks on a Mac you have to install g++ via homebrew or a similar package manager. The default compiler on MacOS is clang and the g++ program is just a copy of clang, which you can verify by running:
g++ --version
Anyway, clang doesn’t support OpenMP, which stacks uses for parallelization, but g++ does. You can find several howto messages in these archives of other who have done it.
Anyway, clang doesn’t support OpenMP, which stacks uses for parallelization, but g++ does. You can find several howto messages in these archives of other who have done it.
--
Stacks website: http://catchenlab.life.illinois.edu/stacks/
---
You received this message because you are subscribed to the Google Groups "Stacks" group.
To unsubscribe from this group and stop receiving emails from it, send an email to stacks-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/stacks-users/PH7PR11MB672296C535B84AF639653D70A7CF2%40PH7PR11MB6722.namprd11.prod.outlook.com.
error: unknown type name 'omp_lock_t'
PackagesNotFoundError: The following packages are not available from current channels:
- bioconda::stacks
- bioconda/label/cf201901::stacks
Has anyone managed to install stacks on mac M3? Any help here would be very much appreciated!
Thank you,
Catarina
If you run the following and see:
% g++ --version
Apple clang version 16.0.0 (clang-1600.0.26.3)
Target: arm64-apple-darwin24.0.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin
You are not running the version of g++ that you installed with homebrew, you are still running the preinstalled Apple clang compiler. You will need to execute the copy you installed, most likely at /opt/homebrew/bin.
From:
stacks...@googlegroups.com <stacks...@googlegroups.com> on behalf of Catarina Silva <catar...@gmail.com>
Date: Friday, October 25, 2024 at 9:11
AM
--
Stacks website: http://catchenlab.life.illinois.edu/stacks/
---
You received this message because you are subscribed to the Google Groups "Stacks" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
stacks-users...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/stacks-users/81a8df39-a63f-465a-9a17-63608de9cc81n%40googlegroups.com.
On my M1 iMac, I ran:
tar xvfz stacks-2.68.tar.gz
cd stacks-2.68
CXX=/opt/homebrew/bin/g++-14 CXXFLAGS="-fopenmp" ./configure
make
And it built without error.