2.66 make error

214 views
Skip to first unread message

Solomon Chak

unread,
Jun 17, 2024, 9:54:35 AM6/17/24
to Stacks

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];

    ^

Catchen, Julian

unread,
Jun 19, 2024, 11:39:45 AM6/19/24
to stacks...@googlegroups.com

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.

David Carlson

unread,
Jun 19, 2024, 12:53:48 PM6/19/24
to stacks...@googlegroups.com
Just a point of clarification regarding the following:


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.

The version of clang provided by LLVM absolutely does support OpenMP.  Even Apple's implementation of clang can be made to use OpenMP when it's installed via homebrew (e.g., see here).

--
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.


--
Dave Carlson, PhD

nyaton kitnya

unread,
Aug 10, 2024, 11:35:26 AM8/10/24
to Stacks
Hi All, 

I am facing the same issue while installing stack 2.67 version in mac Sonoma 14.6. 
I tried to follow the comments from Catchen, David Carlson: installed gcc, but this does not work. After installation of gcc, when I run the function 'make' after './configure' I still get the same error as mentioned above by Solomon Chak.

Can you please direct where am I going wrong? I new to working in terminal.

Thank you so much for the help in advance.

Warm Regards
Nyaton Kitnya

nyaton kitnya

unread,
Aug 16, 2024, 9:56:14 AM8/16/24
to Stacks
Hi all, 

I wanted to update that this issue is resolved. So please ignore this question from now onward.
I installed the STACKS 2.65 version via Anaconda. 

Thank you

Regards
Nyaton

Catarina Silva

unread,
Oct 25, 2024, 10:11:23 AM10/25/24
to Stacks
Hi everyone,

I am having the same issue here on on mac M3. 

I have tried to install stacks-2.68 using brew (gcc and g++  version 16.0.0) and get the same: 

error: unknown type name 'omp_lock_t'



I have also tried to install stacksv2.65 from bioconda but it says:

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



Catchen, Julian

unread,
Oct 25, 2024, 11:13:05 AM10/25/24
to stacks...@googlegroups.com

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.

Catchen, Julian

unread,
Oct 25, 2024, 11:28:34 AM10/25/24
to stacks...@googlegroups.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.

 

Catarina Silva

unread,
Oct 25, 2024, 2:33:54 PM10/25/24
to Stacks
Thank you Julian! It worked this way.
Reply all
Reply to author
Forward
0 new messages