<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    Professor,<br>
    <br>
    I am struggling with this issue as well. When I run "gcc -Wall cmp.c
    ls.c main.c print.c util.c -o ls" there are a <i>lot</i> of errors
    shown. I understand that Linux has functionally equivalent functions
    for some things, but many of these errors have to do with undefined
    constants (HN_AUTOSCALE, HN_NOSPACE), missing header files (util.h,
    tzfile.h), and missing data structure members (no st_mtimensec in
    struct stat). <br>
    <br>
    Even compiling without -Wall, I count 64 warnings and errors.<br>
    <br>
    I don't know if all this was the intent of the assignment, but at
    what point do we draw the line between trying to fix everything and
    simply removing code that is not defined?<br>
    <br>
    -Rob<br>
    <br>
    On 12/4/2011 5:40 PM, Jan Schaumann wrote:
    <blockquote cite="mid:20111204224053.GM22948@netmeister.org"
      type="cite">
      <pre wrap="">Simon Sidhom <a class="moz-txt-link-rfc2396E" href="mailto:ssidhom@stevens.edu"><ssidhom@stevens.edu></a> wrote:

</pre>
      <blockquote type="cite">
        <pre wrap="">I'm not sure if we talked about this in class but I am having a lot of
trouble getting the NetBSD version of ls to compile on the linux lab. There
is no util.h and I get a long list of errors from references to functions
that don't exist. Did you teach us a more practical way of dealing with
this instead of re-writing all of the missing functions?
</pre>
      </blockquote>
      <pre wrap="">
You don't have to write any new functions yourself.  Whatever functions
are called that are not available on linux can be replaced with
functionally equivalent calls to existing functions or with minor tweaks
here and there.

</pre>
      <blockquote type="cite">
        <pre wrap="">I feel like I'm working too hard for this to be a homework about CVS,
diff, and patch.
</pre>
      </blockquote>
      <pre wrap="">
The "porting" of the software is one of the so-called "hidden
requirements", but in this case the changes you'd have to make to have
this version of ls build and function on the linux systems are not very
large.

-Jan
_______________________________________________
cs631apue mailing list
<a class="moz-txt-link-abbreviated" href="mailto:cs631apue@lists.stevens.edu">cs631apue@lists.stevens.edu</a>
<a class="moz-txt-link-freetext" href="https://lists.stevens.edu/cgi-bin/mailman/listinfo/cs631apue">https://lists.stevens.edu/cgi-bin/mailman/listinfo/cs631apue</a>
</pre>
    </blockquote>
    <br>
  </body>
</html>