Ticket #4265 (new Bugs)

Opened 3 years ago

Last modified 3 years ago

patches to make it mostly run on FreeBSD 8.0

Reported by: kurtlidl Assigned to:
Priority: minor Milestone: Undetermined
Component: FreePBX Framework Version: 2.7-branch
Keywords: Cc:
Confirmation: Unreviewed Distro:
Backend Engine: All Distro Ver:
Backend Ver: SVN Revision (if applicable):

Description

I have ported the current 2.8-ish trunk code to mostly run on FreeBSD 8.0.

Attached is a patch file that has all the enhancements.

One of the things about running Asterisk on FreeBSD is that the configuration isn't located in /etc/asterisk, as it is on Linux machines. It's in /usr/local/etc/asterisk. Also, the binaries for Asterisk are installed in various places under /usr/local, not in /usr/sbin.

Finally, the shell on FreeBSD is not Bash, but another Bourne-like shell. I've converted the bash scripts to be just /bin/sh -- which should work equally well under Bash, or any of the other "Bourne like" shells in existance.

I've had to find a few places where the /etc/asterisk directory was still hard-coded into the code, rather than looking it up from the amp_conf array.

Any finally, a note about the sed invocations in the apply_conf.sh script. These were changed at some to handle whitespace around the equals sign, but use a perl-style regular expression for whitespace (\s). The sed on FreeBSD doesn't accept perl-style regexs, so I changed that code to just use the basic regex notation for spaces and tabs. I also changed this to be a single sed invocation, so it creates a single .bak file, rather than 3 .bak files in quick succession.

I hope this can make it in before the 2.8 release. It would be very nice if it could be evaluated for that release.

Attachments

freebsd.patch (9.6 kB) - added by kurtlidl on 05/11/10 14:14:19.

Change History

05/11/10 14:14:19 changed by kurtlidl

  • attachment freebsd.patch added.

05/11/10 14:16:56 changed by kurtlidl

Oops. The patch for apply_conf.sh should just be "#! /bin/sh" not "#! /bin/sh -x" as the invocation line.

Sorry about that.

Also, that patch is against the trunk SVN as of this morning, not against the 2.7-branch, as indicated in the bug report.

05/14/10 17:41:05 changed by p_lindheimer

  • owner deleted.
  • component changed from - choose - to FreePBX Framework.
  • milestone changed from 2.8 to Cut Line.