Problem with deprecated auto_ptr when installing cpptest on 18.04












0















I am trying to install cpptest from https://sourceforge.net/projects/cpptest/ and I am getting compile errors.



A sample error is:



g++ -DHAVE_CONFIG_H -I. -I../config      -g -O2 -MT mytest.o -MD -MP -MF .deps/mytest.Tpo -c -o mytest.o mytest.cpp
In file included from ../src/cpptest.h:34:0,
from mytest.cpp:39:
../src/cpptest-suite.h:58:17: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
void add(std::auto_ptr<Suite> suite);
^~~~~~~~
In file included from /usr/include/c++/7/memory:80:0,
from ../src/cpptest-suite.h:33,
from ../src/cpptest.h:34,
from mytest.cpp:39:
/usr/include/c++/7/bits/unique_ptr.h:51:28: note: declared here
template<typename> class auto_ptr;


Looking at /usr/include/c++/7/bits/unique_ptr.h:51, I see:



 #if _GLIBCXX_USE_DEPRECATED
template<typename> class auto_ptr;
#endif


There doesn't seem to be any way to turn off _GLIBCXX_USE_DEPRECATED. If so, this seems to conflict with the default to report the error.



What is the proper thing to do at this point?










share|improve this question























  • Those appear to be warnings - not errors. Regardless, it looks like the project moved to github several years ago: github.com/cpptest/cpptest

    – steeldriver
    Jan 2 at 0:27











  • The gitub release has an open issue (#1) about completing the migration to github.doesn't have the configure file referenced in the INSTALL document

    – sreich
    Jan 2 at 0:41











  • ... you create the configure script by running the provided autogen script, ./autogen.sh

    – steeldriver
    Jan 2 at 0:48











  • @steeldriver. Thanks. I wasn't aware of that. I was trying to use the raw autoconf.

    – sreich
    Jan 2 at 0:54











  • @steeldriver And still getting the same errors. I will need to look at the cpptest code some more. Probably need to change some code there.

    – sreich
    Jan 2 at 0:57
















0















I am trying to install cpptest from https://sourceforge.net/projects/cpptest/ and I am getting compile errors.



A sample error is:



g++ -DHAVE_CONFIG_H -I. -I../config      -g -O2 -MT mytest.o -MD -MP -MF .deps/mytest.Tpo -c -o mytest.o mytest.cpp
In file included from ../src/cpptest.h:34:0,
from mytest.cpp:39:
../src/cpptest-suite.h:58:17: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
void add(std::auto_ptr<Suite> suite);
^~~~~~~~
In file included from /usr/include/c++/7/memory:80:0,
from ../src/cpptest-suite.h:33,
from ../src/cpptest.h:34,
from mytest.cpp:39:
/usr/include/c++/7/bits/unique_ptr.h:51:28: note: declared here
template<typename> class auto_ptr;


Looking at /usr/include/c++/7/bits/unique_ptr.h:51, I see:



 #if _GLIBCXX_USE_DEPRECATED
template<typename> class auto_ptr;
#endif


There doesn't seem to be any way to turn off _GLIBCXX_USE_DEPRECATED. If so, this seems to conflict with the default to report the error.



What is the proper thing to do at this point?










share|improve this question























  • Those appear to be warnings - not errors. Regardless, it looks like the project moved to github several years ago: github.com/cpptest/cpptest

    – steeldriver
    Jan 2 at 0:27











  • The gitub release has an open issue (#1) about completing the migration to github.doesn't have the configure file referenced in the INSTALL document

    – sreich
    Jan 2 at 0:41











  • ... you create the configure script by running the provided autogen script, ./autogen.sh

    – steeldriver
    Jan 2 at 0:48











  • @steeldriver. Thanks. I wasn't aware of that. I was trying to use the raw autoconf.

    – sreich
    Jan 2 at 0:54











  • @steeldriver And still getting the same errors. I will need to look at the cpptest code some more. Probably need to change some code there.

    – sreich
    Jan 2 at 0:57














0












0








0








I am trying to install cpptest from https://sourceforge.net/projects/cpptest/ and I am getting compile errors.



A sample error is:



g++ -DHAVE_CONFIG_H -I. -I../config      -g -O2 -MT mytest.o -MD -MP -MF .deps/mytest.Tpo -c -o mytest.o mytest.cpp
In file included from ../src/cpptest.h:34:0,
from mytest.cpp:39:
../src/cpptest-suite.h:58:17: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
void add(std::auto_ptr<Suite> suite);
^~~~~~~~
In file included from /usr/include/c++/7/memory:80:0,
from ../src/cpptest-suite.h:33,
from ../src/cpptest.h:34,
from mytest.cpp:39:
/usr/include/c++/7/bits/unique_ptr.h:51:28: note: declared here
template<typename> class auto_ptr;


Looking at /usr/include/c++/7/bits/unique_ptr.h:51, I see:



 #if _GLIBCXX_USE_DEPRECATED
template<typename> class auto_ptr;
#endif


There doesn't seem to be any way to turn off _GLIBCXX_USE_DEPRECATED. If so, this seems to conflict with the default to report the error.



What is the proper thing to do at this point?










share|improve this question














I am trying to install cpptest from https://sourceforge.net/projects/cpptest/ and I am getting compile errors.



A sample error is:



g++ -DHAVE_CONFIG_H -I. -I../config      -g -O2 -MT mytest.o -MD -MP -MF .deps/mytest.Tpo -c -o mytest.o mytest.cpp
In file included from ../src/cpptest.h:34:0,
from mytest.cpp:39:
../src/cpptest-suite.h:58:17: warning: ‘template<class> class std::auto_ptr’ is deprecated [-Wdeprecated-declarations]
void add(std::auto_ptr<Suite> suite);
^~~~~~~~
In file included from /usr/include/c++/7/memory:80:0,
from ../src/cpptest-suite.h:33,
from ../src/cpptest.h:34,
from mytest.cpp:39:
/usr/include/c++/7/bits/unique_ptr.h:51:28: note: declared here
template<typename> class auto_ptr;


Looking at /usr/include/c++/7/bits/unique_ptr.h:51, I see:



 #if _GLIBCXX_USE_DEPRECATED
template<typename> class auto_ptr;
#endif


There doesn't seem to be any way to turn off _GLIBCXX_USE_DEPRECATED. If so, this seems to conflict with the default to report the error.



What is the proper thing to do at this point?







gcc c++






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Jan 2 at 0:10









sreichsreich

1




1













  • Those appear to be warnings - not errors. Regardless, it looks like the project moved to github several years ago: github.com/cpptest/cpptest

    – steeldriver
    Jan 2 at 0:27











  • The gitub release has an open issue (#1) about completing the migration to github.doesn't have the configure file referenced in the INSTALL document

    – sreich
    Jan 2 at 0:41











  • ... you create the configure script by running the provided autogen script, ./autogen.sh

    – steeldriver
    Jan 2 at 0:48











  • @steeldriver. Thanks. I wasn't aware of that. I was trying to use the raw autoconf.

    – sreich
    Jan 2 at 0:54











  • @steeldriver And still getting the same errors. I will need to look at the cpptest code some more. Probably need to change some code there.

    – sreich
    Jan 2 at 0:57



















  • Those appear to be warnings - not errors. Regardless, it looks like the project moved to github several years ago: github.com/cpptest/cpptest

    – steeldriver
    Jan 2 at 0:27











  • The gitub release has an open issue (#1) about completing the migration to github.doesn't have the configure file referenced in the INSTALL document

    – sreich
    Jan 2 at 0:41











  • ... you create the configure script by running the provided autogen script, ./autogen.sh

    – steeldriver
    Jan 2 at 0:48











  • @steeldriver. Thanks. I wasn't aware of that. I was trying to use the raw autoconf.

    – sreich
    Jan 2 at 0:54











  • @steeldriver And still getting the same errors. I will need to look at the cpptest code some more. Probably need to change some code there.

    – sreich
    Jan 2 at 0:57

















Those appear to be warnings - not errors. Regardless, it looks like the project moved to github several years ago: github.com/cpptest/cpptest

– steeldriver
Jan 2 at 0:27





Those appear to be warnings - not errors. Regardless, it looks like the project moved to github several years ago: github.com/cpptest/cpptest

– steeldriver
Jan 2 at 0:27













The gitub release has an open issue (#1) about completing the migration to github.doesn't have the configure file referenced in the INSTALL document

– sreich
Jan 2 at 0:41





The gitub release has an open issue (#1) about completing the migration to github.doesn't have the configure file referenced in the INSTALL document

– sreich
Jan 2 at 0:41













... you create the configure script by running the provided autogen script, ./autogen.sh

– steeldriver
Jan 2 at 0:48





... you create the configure script by running the provided autogen script, ./autogen.sh

– steeldriver
Jan 2 at 0:48













@steeldriver. Thanks. I wasn't aware of that. I was trying to use the raw autoconf.

– sreich
Jan 2 at 0:54





@steeldriver. Thanks. I wasn't aware of that. I was trying to use the raw autoconf.

– sreich
Jan 2 at 0:54













@steeldriver And still getting the same errors. I will need to look at the cpptest code some more. Probably need to change some code there.

– sreich
Jan 2 at 0:57





@steeldriver And still getting the same errors. I will need to look at the cpptest code some more. Probably need to change some code there.

– sreich
Jan 2 at 0:57










1 Answer
1






active

oldest

votes


















0














The messages are warnings, not errors.



They can be suppressed by passing the -Wno-deprecated compilation flag:




   -Wno-deprecated
Do not warn about usage of deprecated features.



ex.



./configure CXXFLAGS=-Wno-deprecated
make




Alternatively, you can install and use an older version of the compiler which doesn't deprecate these code features



./configure CC=/usr/bin/gcc-5 CXX=/usr/bin/g++-5





share|improve this answer


























  • Yes! Turning off the warning did it.

    – sreich
    Jan 2 at 1:17













Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "89"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1106117%2fproblem-with-deprecated-auto-ptr-when-installing-cpptest-on-18-04%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























1 Answer
1






active

oldest

votes








1 Answer
1






active

oldest

votes









active

oldest

votes






active

oldest

votes









0














The messages are warnings, not errors.



They can be suppressed by passing the -Wno-deprecated compilation flag:




   -Wno-deprecated
Do not warn about usage of deprecated features.



ex.



./configure CXXFLAGS=-Wno-deprecated
make




Alternatively, you can install and use an older version of the compiler which doesn't deprecate these code features



./configure CC=/usr/bin/gcc-5 CXX=/usr/bin/g++-5





share|improve this answer


























  • Yes! Turning off the warning did it.

    – sreich
    Jan 2 at 1:17


















0














The messages are warnings, not errors.



They can be suppressed by passing the -Wno-deprecated compilation flag:




   -Wno-deprecated
Do not warn about usage of deprecated features.



ex.



./configure CXXFLAGS=-Wno-deprecated
make




Alternatively, you can install and use an older version of the compiler which doesn't deprecate these code features



./configure CC=/usr/bin/gcc-5 CXX=/usr/bin/g++-5





share|improve this answer


























  • Yes! Turning off the warning did it.

    – sreich
    Jan 2 at 1:17
















0












0








0







The messages are warnings, not errors.



They can be suppressed by passing the -Wno-deprecated compilation flag:




   -Wno-deprecated
Do not warn about usage of deprecated features.



ex.



./configure CXXFLAGS=-Wno-deprecated
make




Alternatively, you can install and use an older version of the compiler which doesn't deprecate these code features



./configure CC=/usr/bin/gcc-5 CXX=/usr/bin/g++-5





share|improve this answer















The messages are warnings, not errors.



They can be suppressed by passing the -Wno-deprecated compilation flag:




   -Wno-deprecated
Do not warn about usage of deprecated features.



ex.



./configure CXXFLAGS=-Wno-deprecated
make




Alternatively, you can install and use an older version of the compiler which doesn't deprecate these code features



./configure CC=/usr/bin/gcc-5 CXX=/usr/bin/g++-5






share|improve this answer














share|improve this answer



share|improve this answer








edited Jan 2 at 1:06

























answered Jan 2 at 0:58









steeldriversteeldriver

66.5k11107179




66.5k11107179













  • Yes! Turning off the warning did it.

    – sreich
    Jan 2 at 1:17





















  • Yes! Turning off the warning did it.

    – sreich
    Jan 2 at 1:17



















Yes! Turning off the warning did it.

– sreich
Jan 2 at 1:17







Yes! Turning off the warning did it.

– sreich
Jan 2 at 1:17




















draft saved

draft discarded




















































Thanks for contributing an answer to Ask Ubuntu!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2faskubuntu.com%2fquestions%2f1106117%2fproblem-with-deprecated-auto-ptr-when-installing-cpptest-on-18-04%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

Ellipse (mathématiques)

Quarter-circle Tiles

Mont Emei