Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 714212

Summary: net-ftp/linksys-tftp-1.2.1-r3 : main.c: error: O_RDONLY undeclared (first use in this function)
Product: Gentoo Linux Reporter: Toralf Förster <toralf>
Component: Current packagesAssignee: Gentoo musl team <musl>
Status: RESOLVED FIXED    
Severity: normal CC: embedded
Priority: Normal Keywords: PullRequest
Version: unspecified   
Hardware: All   
OS: Linux   
See Also: https://github.com/gentoo/gentoo/pull/36399
Whiteboard: Missing fcntl.h?
Package list:
Runtime testing required: ---
Bug Depends on:    
Bug Blocks: 713786    
Attachments: emerge-info.txt
emerge-history.txt
environment
etc.portage.tbz2
net-ftp:linksys-tftp-1.2.1-r3:20200324-135426.log
temp.tbz2

Description Toralf Förster gentoo-dev 2020-03-24 15:58:49 UTC
      |        ^~~~
      |        popen
main.c:276:17: error: O_RDONLY undeclared (first use in this function)
  276 |   fd = open(cp, O_RDONLY);
      |                 ^~~~~~~~
main.c:276:17: note: each undeclared identifier is reported only once for each function it appears in

  -------------------------------------------------------------------

  This is an unstable amd64 chroot image at a tinderbox (==build bot)
  name: 17.0_musl-20200316-165821

  -------------------------------------------------------------------

  Please see the tracker bug for details.

gcc-config -l:
 [1] x86_64-gentoo-linux-musl-9.3.0 *
clang version 10.0.0 
Target: x86_64-gentoo-linux-musl
Thread model: posix
InstalledDir: /usr/lib/llvm/10/bin
/usr/lib/llvm/10
10.0.0
Available Python interpreters, in order of preference:
  [1]   python3.8
  [2]   python3.7
  [3]   python3.6
  [4]   python2.7 (fallback)
Available Ruby profiles:
  [1]   ruby24 (with Rubygems)
  [2]   ruby25 (with Rubygems) *
Available Rust versions:
  [1]   rust-1.41.1 *
  [2]   rust-bin-1.42.0

timestamp of HEAD at this tinderbox image:
/var/db/repos/gentoo	Tue Mar 24 12:08:56 UTC 2020
/var/db/repos/musl	Sun Mar 22 15:02:57 UTC 2020

emerge -qpvO net-ftp/linksys-tftp
[ebuild  N    ] net-ftp/linksys-tftp-1.2.1-r3
Comment 1 Toralf Förster gentoo-dev 2020-03-24 15:58:52 UTC
Created attachment 625174 [details]
emerge-info.txt
Comment 2 Toralf Förster gentoo-dev 2020-03-24 15:58:54 UTC
Created attachment 625176 [details]
emerge-history.txt
Comment 3 Toralf Förster gentoo-dev 2020-03-24 15:58:57 UTC
Created attachment 625178 [details]
environment
Comment 4 Toralf Förster gentoo-dev 2020-03-24 15:59:00 UTC
Created attachment 625180 [details]
etc.portage.tbz2
Comment 5 Toralf Förster gentoo-dev 2020-03-24 15:59:03 UTC
Created attachment 625182 [details]
net-ftp:linksys-tftp-1.2.1-r3:20200324-135426.log
Comment 6 Toralf Förster gentoo-dev 2020-03-24 15:59:05 UTC
Created attachment 625184 [details]
temp.tbz2
Comment 7 Michael 'veremitz' Everitt 2020-03-29 22:13:35 UTC
Likely an occurrence of missing #include <fcntl.h>.
Comment 8 Larry the Git Cow gentoo-dev 2024-04-29 05:32:07 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=9041943e464b5d219db2101df1eebcab907e4b60

commit 9041943e464b5d219db2101df1eebcab907e4b60
Author:     NHOrus <jy6x2b32pie9@yahoo.com>
AuthorDate: 2024-04-24 10:59:21 +0000
Commit:     Viorel Munteanu <ceamac@gentoo.org>
CommitDate: 2024-04-29 05:18:39 +0000

    net-ftp/linksys-tftp: Port to C99, fix compile on musl systems
    
    Primary patch by Richard Narron from bug 928051
    Musl fix by me.
    
    Closes: https://bugs.gentoo.org/928051
    Closes: https://bugs.gentoo.org/714212
    Closes: https://bugs.gentoo.org/874582
    Closes: https://bugs.gentoo.org/885699
    Closes: https://bugs.gentoo.org/913577
    Signed-off-by: NHOrus <jy6x2b32pie9@yahoo.com>
    Closes: https://github.com/gentoo/gentoo/pull/36399
    Signed-off-by: Viorel Munteanu <ceamac@gentoo.org>

 .../files/linksys-tftp-1.2.1-r4-c99-port.patch     | 572 +++++++++++++++++++++
 net-ftp/linksys-tftp/linksys-tftp-1.2.1-r4.ebuild  |  31 ++
 2 files changed, 603 insertions(+)