Opened 16 years ago

Closed 16 years ago

Last modified 15 years ago

#15455 closed defect (duplicate)

srm-1.2.8 runtime error - cannot remove files

Reported by: vogt@… Owned by: macports-tickets@…
Priority: Normal Milestone:
Component: ports Version: 1.6.0
Keywords: srm, dyld, fdatasync, flat namespace Cc:
Port:

Description

The Error

srm-1.2.8 will compile fine via MacPorts. However, when you attempt to use it to remove a file (the intended purpose of srm), the following error occurs:

% srm myFile
dyld: lazy symbol binding failed: Symbol not found: _fdatasync
  Referenced from: /opt/local/bin/srm
  Expected in: flat namespace

dyld: Symbol not found: _fdatasync
  Referenced from: /opt/local/bin/srm
  Expected in: flat namespace

Trace/BPT trap

Previous Report of this Error

This error was previously reported as Ticket #9899 approximately two years ago, but no solution was posted to Ticket #9899. I have a patch for this runtime error; however, I was unsure of whether I should reply to Ticket #9899 with this patch or start a new ticket for the patch (the MacPorts documentation seemed ambiguous on this matter: Section 7.2.2 of http://guide.macports.org/ seems to say that a new ticket should be started, but Point 2 in http://trac.macports.org/wiki/TracTicketing says that a reply is in order). I posted the patch to Ticket #9899 approximately one week ago, along with a request to inform me if this was the correct course of action (as opposed to starting a new ticket). Since I have not heard anything back, I decided it would be best to start a new ticket for the patch.

The Patch

The patch simply removes some unnecessary CFLAGS from the Portfile build of srm-1.2.8. Since srm compiles and runs fine if you use the soruce tarball directly from srm's homepage (i.e., not through MacPorts) with no extra flags or configuration options, I'm not sure why these CFLAGS were added to the Portfile build in the first place. If they were added for compatibility purposes with an older OS X version (e.g., 10.3?), I would have no way of testing that. Based on the report in Ticket #9899, as well as my own experiences, srm-1.2.8 will not work properly on OS X 10.4 or 10.5 without a patch.

I have tested this patch on OS X 10.5, running the current version of MacPorts (1.6.0).

Attachments (1)

Portfile-srm.diff (349 bytes) - added by vogt@… 16 years ago.
Patch to srm-1.2.8 Portfile to fix runtime error

Download all attachments as: .zip

Change History (3)

Changed 16 years ago by vogt@…

Attachment: Portfile-srm.diff added

Patch to srm-1.2.8 Portfile to fix runtime error

comment:1 Changed 16 years ago by jmroot (Joshua Root)

Resolution: duplicate
Status: newclosed

Commenting on the existing ticket is the right thing to do, so I'm marking this one as a duplicate of #9899. If no one seems to notice when you attach a fix to a ticket, ask on the macports-dev list or on IRC.

comment:2 Changed 15 years ago by (none)

Milestone: Port Bugs

Milestone Port Bugs deleted

Note: See TracTickets for help on using tickets.