Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

Update: after fiddling around I found out that any makefile in the tests subdirectory is ignored, so I probably am missing something when writing my main Makefile.am. After a bit of fiddling around I still have the error output, yet when I run make check-local I get undefined references error
This is not surprising since the gcc command run does not include either the tap files or the main program's c files


YAU(yet another update) I managed to make it work but I did not follow the c tap harness author instructions : I added a line to my Makefile.am so it builds the test executable before running the test suite, that way everything works fine. Still it feels a bit unelegant and like cheating, am I doing things right?

So after some studying I think I'm starting to get autotools to do what I want (at least autoconf et automake) right now I'm confronted with a bit of a conundrum :

For any test programs that need to be compiled, add build rules for them in Makefile.am, simliar to:
tests_libtap_c_basic_LDADD = tests/tap/libtap.a

this line is quite a mysterious : as I understand it, if I have in my tests directory a subfolder containing tests for a specific c file (lets call that test file specific_tests.c) to have the harness run those tests I'd need to add to Makefile.am the following line :

specific_tests_LDADD=tests/tab/libtap.

Thing is if I add this line and then autoreconf I got the following output :

Makefile.am:10: warning: variable 'specific_tests_LDADD' is defined bu +t no program or Makefile.am:10: library has 'specific_tests' as canonical name (possib +le typo)

I must add that if I compile specific_tests myself into a specific_tests.t output file make checklocal runs perfectly "


In reply to Re^4: C test suite management with perl by QuillMeantTen
in thread C test suite management with perl by QuillMeantTen

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (4)
As of 2024-04-25 15:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found