Opened 3 years ago

Closed 3 years ago

#62513 closed defect (fixed)

ncbi_tools: error: implicit declaration of function 'write' is invalid in C99

Reported by: seanhemmingsen Owned by: weitzner (Brian Weitzner)
Priority: Normal Milestone:
Component: ports Version:
Keywords: Cc:
Port: ncbi_tools

Description

after clean, uninstall, selfupdate, install ncbi_tools failed.

Attachments (2)

Failed_to_build_ncbi_tools_main.log (200.6 KB) - added by seanhemmingsen 3 years ago.
fix-macos-build.patch (1.8 KB) - added by weitzner (Brian Weitzner) 3 years ago.
patch-file

Download all attachments as: .zip

Change History (7)

Changed 3 years ago by seanhemmingsen

comment:1 Changed 3 years ago by mf2k (Frank Schima)

Port: ncbi_tools added

In the future, please fill in the Port field.

comment:2 Changed 3 years ago by mf2k (Frank Schima)

Error appears to be :

:info:build viewgif.c:115:5: error: implicit declaration of function 'write' is invalid in C99 [-Werror,-Wimplicit-function-declaration]
:info:build     write(1, tmp_buff, strlen(tmp_buff));

comment:3 Changed 3 years ago by mf2k (Frank Schima)

Summary: Failed to build ncbi_tools: command execution failedncbi_tools: error: implicit declaration of function 'write' is invalid in C99

comment:4 Changed 3 years ago by weitzner (Brian Weitzner)

I downloaded the source and attempted to work through this and found the following steps to be necessary:

asn2gnb2.c:63

#include <ffprint.h>

salutil.c:54

#include <alignmgr2.h>

viewgif.c:48

#include <unistd.h>

wblast.c:298

#include <algo/blast/core/blast_util.h>
#include <accid1.h>

After making those changes I can build the tool locally and the executable I am interested in seems to be working correctly. I would be happy to contribute this fix, but as it would be my first port contribution I might look for a little guidance. Thanks!

Version 0, edited 3 years ago by weitzner (Brian Weitzner) (next)

Changed 3 years ago by weitzner (Brian Weitzner)

Attachment: fix-macos-build.patch added

patch-file

comment:5 Changed 3 years ago by weitzner (Brian Weitzner)

Owner: set to weitzner
Resolution: fixed
Status: newclosed

In c389d839fbd5599c2b6d088b5f7447cc44edf82c/macports-ports (master):

ncbi_tools: update to version 20120620

  • update to version 20120620
  • add new patch file to fix compilation issues
  • remove outdated patch files
  • update Portfile to copy the correct binaries and data files
  • fixing remaining warnings in portfile

Closes: #19513
Closes: #62513

Note: See TracTickets for help on using tickets.