<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>Ubuntu compile - open_missing_mode error</title>
  <link rel="self" href="https://dlt-acc.firelay.cloud/c/message_boards/find_thread?p_l_id=3231581&amp;threadId=3397376" />
  <subtitle>Ubuntu compile - open_missing_mode error</subtitle>
  <id>https://dlt-acc.firelay.cloud/c/message_boards/find_thread?p_l_id=3231581&amp;threadId=3397376</id>
  <updated>2026-05-15T15:06:43Z</updated>
  <dc:date>2026-05-15T15:06:43Z</dc:date>
  <entry>
    <title>RE: Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3398001" />
    <author>
      <name>Mario Luiz Mascagni</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3398001</id>
    <updated>2018-07-09T23:40:28Z</updated>
    <published>2018-07-09T23:40:28Z</published>
    <summary type="html">&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I am sorry, but I've been playing with the d3d code without
  understand whats is really going on. I knew the problem was in the
  line 1296 of the oc.c script, so I changed that line to the 1297 line
  as in the following piece of the code: &lt;/p&gt;
&lt;p&gt;#########################################################&lt;/p&gt;
&lt;p&gt;
  &lt;em&gt;1286  /* open file with appropriate access type&lt;br /&gt; 1287
    */&lt;br /&gt; 1288   if ( fds == -1 )&lt;br /&gt; 1289   {&lt;br /&gt; 1290       if
    ( acType == FILE_CREATE )&lt;br /&gt; 1291       {&lt;br /&gt; 1292         
    fds   = FILE_OPEN( file_name, acType, FILE_MODE );&lt;br /&gt; 1293      
    }&lt;br /&gt; 1294   else&lt;br /&gt; 1295   {&lt;br /&gt; 1296   /*       fds   =
    FILE_OPEN( file_name, acType );                         */&lt;br /&gt;
    1297            fds   = FILE_OPEN( file_name, acType, FILE_MODE
    );&lt;br /&gt; 1298       }&lt;br /&gt; 1299   }&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;##########################################################&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;This change worked for me to compile the trunk version, once
    &lt;em&gt;fcntl2.h require a third argument for FILE_OPEN.&lt;/em&gt;&lt;/p&gt;
&lt;p&gt;I am sorry again for change the code in that way, I hope somebody who
  knows what are doing may fix this part of the code in a near future.&lt;/p&gt;
&lt;p&gt;best regards&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Mario Luiz Mascagni</dc:creator>
    <dc:date>2018-07-09T23:40:28Z</dc:date>
  </entry>
  <entry>
    <title>RE: Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397990" />
    <author>
      <name>Mario Luiz Mascagni</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397990</id>
    <updated>2018-07-06T19:15:53Z</updated>
    <published>2018-07-06T19:15:53Z</published>
    <summary type="html">&lt;p&gt;Hi Dri,&lt;/p&gt;
&lt;p&gt;I am also having the same problem trying to compile the vesion 7545
  and trunk versions on Linux Gentoo.&lt;/p&gt;
&lt;p&gt;I dont know how to solve this problem yet, but the there are some
  significant changes in glibc-2.27 in relation to glibc-2.25 - when I
  last compiled version 7545 succesfully. So now glibc is
  calling fcntl2.h to compile oc.o, and the error is that should have 3
  arguments to open_nefis_file’ at oc.c:1296:19, but there is only 2.&lt;/p&gt;
&lt;p&gt;The only way I manage to compile Delft3D again was downgrading gcc to
  gcc-6.4.0 in order to downgrade glibc to glibc-2.25, but I messed my
  system a litle doind that.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Mario Luiz Mascagni</dc:creator>
    <dc:date>2018-07-06T19:15:53Z</dc:date>
  </entry>
  <entry>
    <title>RE: Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397855" />
    <author>
      <name>Marcelo Gagliardi</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397855</id>
    <updated>2018-06-29T16:49:31Z</updated>
    <published>2018-06-29T16:49:31Z</published>
    <summary type="html">&lt;p&gt;Hi Adri,&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Thanks for the answer. Sorry for the incomplete post.&lt;/p&gt;
&lt;p&gt;I'm trying to compile the tag version 7545, and I followed the
  instructions on the build_ubuntu.16.04LT.readme file that
  you mentioned. I fact, I succeed in compiling this version on a
  vm with ubuntu 16.04 following these instructions, but it's not
  working on ubuntu server 17. I will compare the logs and see if can
  found the error, in the meantime, I am sending the logs that you mentioned.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Thanks for attention.&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Marcelo&lt;/p&gt;</summary>
    <dc:creator>Marcelo Gagliardi</dc:creator>
    <dc:date>2018-06-29T16:49:31Z</dc:date>
  </entry>
  <entry>
    <title>RE: Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397842" />
    <author>
      <name>Adri Mourits</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397842</id>
    <updated>2018-06-29T16:15:45Z</updated>
    <published>2018-06-29T16:15:45Z</published>
    <summary type="html">&lt;p&gt;Hi Marcelo,&lt;/p&gt;
&lt;p&gt;File &amp;quot;fcntl2.h&amp;quot; should not be used when compiling
  &amp;quot;oc.c&amp;quot;. Your post above only contains the error message. The
  lines in stdout just before these messages contain the compile
  command, with all its arguments. Does that give a clue about what goes wrong?&lt;/p&gt;
&lt;p&gt;Directory &lt;a
  href="https://svn.oss.deltares.nl/repos/delft3d/trunk/src"&gt;https://svn.oss.deltares.nl/repos/delft3d/trunk/src&lt;/a&gt; contains
  two files about compiling on Ubuntu:&lt;br /&gt;
  build_ubuntu.16.04LT.readme&lt;br /&gt; build_ubuntu1604.sh&lt;br /&gt; Does the
  information in there help?&lt;/p&gt;
&lt;p&gt;Directory &lt;a
  href="https://svn.oss.deltares.nl/repos/delft3d/trunk/src/logs"&gt;https://svn.oss.deltares.nl/repos/delft3d/trunk/src/logs&lt;/a&gt; contains
  the full output of autogen/configure/make. It's a little bit outdated,
  but might be useful for you to compare with.&lt;/p&gt;
&lt;p&gt;If you still have compilation problems, please attach the full output
  of autogen/configure/make to a post on this forum.&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Adri&lt;/p&gt;</summary>
    <dc:creator>Adri Mourits</dc:creator>
    <dc:date>2018-06-29T16:15:45Z</dc:date>
  </entry>
  <entry>
    <title>RE: Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397672" />
    <author>
      <name>Marcelo Gagliardi</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397672</id>
    <updated>2018-06-25T17:15:33Z</updated>
    <published>2018-06-25T17:15:33Z</published>
    <summary type="html">&lt;p&gt;Hi Seb and Adri,&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I have been trying to compile delft on Ubuntu server for a couple of
  days and I'm getting a similar error:&lt;/p&gt;
&lt;p&gt;In function ‘open’,&lt;br /&gt;     inlined from ‘open_nefis_file’ at
  oc.c:1296:19:&lt;br /&gt; /usr/include/x86_64-linux-gnu/bits/fcntl2.h:50:4:
  error: call to ‘__open_missing_mode’ declared with attribute error:
  open with O_CREAT or O_TMPFILE in second argument needs 3
  arguments&lt;br /&gt;     __open_missing_mode ();&lt;br /&gt;    
  ^~~~~~~~~~~~~~~~~~~~~~&lt;br /&gt; Makefile:567: recipe for target 'oc.lo'
  failed&lt;br /&gt; make[6]: *** [oc.lo] Error 1&lt;br /&gt; make[6]: Leaving
  directory
  '/home/beowolf/delft3dtag/src/utils_lgpl/nefis/packages/nefis/src'&lt;br /&gt;
  Makefile:688: recipe for target 'install' failed&lt;br /&gt; make[5]: ***
  [install] Error 2&lt;br /&gt; make[5]: Leaving directory
  '/home/beowolf/delft3dtag/src/utils_lgpl/nefis/packages/nefis/src'&lt;br /&gt;
  Makefile:490: recipe for target 'install-recursive' failed&lt;br /&gt;
  make[4]: *** [install-recursive] Error 1&lt;br /&gt; make[4]: Leaving
  directory
  '/home/beowolf/delft3dtag/src/utils_lgpl/nefis/packages/nefis'&lt;br /&gt;
  Makefile:489: recipe for target 'install-recursive' failed&lt;br /&gt;
  make[3]: *** [install-recursive] Error 1&lt;br /&gt; make[3]: Leaving
  directory
  '/home/beowolf/delft3dtag/src/utils_lgpl/nefis/packages'&lt;br /&gt;
  Makefile:491: recipe for target 'install-recursive' failed&lt;br /&gt;
  make[2]: *** [install-recursive] Error 1&lt;br /&gt; make[2]: Leaving
  directory '/home/beowolf/delft3dtag/src/utils_lgpl/nefis'&lt;br /&gt;
  Makefile:499: recipe for target 'install-recursive' failed&lt;br /&gt;
  make[1]: *** [install-recursive] Error 1&lt;br /&gt; make[1]: Leaving
  directory '/home/beowolf/delft3dtag/src/utils_lgpl'&lt;br /&gt;
  Makefile:549: recipe for target 'install-recursive' failed&lt;br /&gt; make:
  *** [install-recursive] Error 1&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I wonder if anybody had solved this one.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Thanks in advance.&lt;/p&gt;
&lt;p&gt;Cheers,&lt;/p&gt;
&lt;p&gt;Marcelo&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;</summary>
    <dc:creator>Marcelo Gagliardi</dc:creator>
    <dc:date>2018-06-25T17:15:33Z</dc:date>
  </entry>
  <entry>
    <title>RE: Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397391" />
    <author>
      <name>Adri Mourits</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397391</id>
    <updated>2018-06-06T18:19:23Z</updated>
    <published>2018-06-06T18:19:23Z</published>
    <summary type="html">&lt;p&gt;Hi Seb,&lt;/p&gt;
&lt;p&gt;The gnu4.6.2.log files you attached are created by me as an example
  of how the output should look like. Can you redirect your output to a
  new file and attach them to a post in this thread?&lt;/p&gt;
&lt;p&gt;What Gnu version are you using?&lt;/p&gt;
&lt;p&gt;Regards,&lt;/p&gt;
&lt;p&gt;Adri&lt;/p&gt;</summary>
    <dc:creator>Adri Mourits</dc:creator>
    <dc:date>2018-06-06T18:19:23Z</dc:date>
  </entry>
  <entry>
    <title>Ubuntu compile - open_missing_mode error</title>
    <link rel="alternate" href="https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397375" />
    <author>
      <name>Seb Pitman</name>
    </author>
    <id>https://dlt-acc.firelay.cloud/c/message_boards/find_message?p_l_id=3231581&amp;messageId=3397375</id>
    <updated>2018-05-31T01:53:13Z</updated>
    <published>2018-05-31T01:53:13Z</published>
    <summary type="html">&lt;p&gt;Hi All,&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I've been trying to compile on Ubuntu for a few days as a new user to
  linux. I've worked out most of the errors so far (these forums have
  been a great help!), but am stumped by the latest one.&lt;/p&gt;
&lt;p&gt;I've run autogen, configure, but on make I'm receiving the following
  error message:&lt;/p&gt;
&lt;hr /&gt;
&lt;p&gt;
  &lt;em&gt;In file included from /usr/include/fcntl.h:290:0,&lt;br /&gt;
                                from oc.c:45:&lt;br /&gt; In function
    ‘open’,&lt;br /&gt;     inlined from ‘open_nefis_file’ at
    oc.c:1296:19:&lt;br /&gt;
    /usr/include/x86_64-linux-gnu/bits/fcntl2.h:50:4: error: call to
    ‘__open_missing_mode’ declared with attribute error: open with
    O_CREAT or O_TMPFILE in second argument needs 3 arguments&lt;br /&gt;    
    __open_missing_mode ();&lt;br /&gt;     ^~~~~~~~~~~~~~~~~~~~~~&lt;br /&gt;
    Makefile:573: recipe for target 'oc.lo' failed&lt;br /&gt; make[7]: ***
    [oc.lo] Error 1&lt;br /&gt; make[7]: Leaving directory '/home/seb/delft3dtrunk/src/utils_lgpl/nefis/packages/nefis/src'&lt;/em&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;I'd be really grateful for any steer on  how to debug! Thanks in
  advance for your help.&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Cheers&lt;/p&gt;
&lt;p&gt;Seb&lt;/p&gt;</summary>
    <dc:creator>Seb Pitman</dc:creator>
    <dc:date>2018-05-31T01:53:13Z</dc:date>
  </entry>
</feed>
