0

FINAL UPDATE: Bitnami will include mod_xsendfile to the MAPP stack as of the next release planned for somewhere around April 8, 2013.


I have tryed compiling and installing mod_xsendfile on my mappstack5.4.12-0. I have tryed two methods, but I have failed each time:

  • Method 1: Automatic install using apxs. Problem => When running command "apxs -cia mod_xsendfile.c", apxs is trying to install mod_xsendfile on my mac instead of installing it on the mappstack and fails because permission is denied when trying to create the .so file in that protected area.

  • Method 2: Compiling with apxs and manual installation in Apache. Problem => When running command "apxs -c mod_xsendfile.c" in a folder that I fully own, it produces a .slo file instead of a .so file.

How can I transform this .slo file into a .so file? I couldn't find any relevant result for .slo files in google, nor anything usefull about my 2 issues.

With a .so file, I could install mod_xsendfile manually in Apache using the instructions found in the following references:

I can't post more than 2 urls, but here is the relevant part for each:

  • web-developpeur-php.com/blog/article/mod-xsendfile-forcer-le-telechargement-avec-apache-php
  • codeutopia.net/blog/2009/03/06/sending-files-better-apache-mod_xsendfile-and-php/
  • elivz.com/blog/single/mod_xsendfile/

Apache manual for apxs: http://httpd.apache.org/docs/2.2/programs/apxs.html

This is my first time using apxs and I don't know much about compiling c code

Thanks.

PS: I was able to install mod_xsendfile on the MAPPstack following instructions in stackoverflow answer https://stackoverflow.com/a/9615149/2193168, but I'm getting errors when restarting Apache.

httpd: Syntax error on line 529 of /Applications/mappstack-5.4.12-0/apache2/conf/httpd.conf:
 Cannot load /Applications/mappstack-5.4.12-0/apache2/modules/mod_xsendfile.so into server:
   dlopen(/Applications/mappstack-5.4.12-0/apache2/modules/mod_xsendfile.so, 10):
     Symbol not found: _ap_log_rerror
       Referenced from: /Applications/mappstack-5.4.12-0/apache2/modules/mod_xsendfile.so
         Expected in: flat namespace
           in /Applications/mappstack-5.4.12-0/apache2/modules/mod_xsendfile.so
Community
  • 1
  • 1
  • FYI: I have asked the same question on the bitnami help forum and will post the final answer on both sites.See: questions/11701/how-to-compile-and-install-mod_xsendfile-on-mapp-stack – Loïc Benoit Mar 21 '13 at 01:23
  • Bitnami is considering the addition of mod_xsendfile to this bitnami stack. If they decide to include it, the easy solution is to wait until they have done so. However, it would still be nice for someone to explain the solution here... – Loïc Benoit Mar 26 '13 at 00:36
  • This other stackoverflow post is relevant and may answer the question: http://stackoverflow.com/questions/9101566/install-apache-module-x-sendfile-on-mamp?rq=1 – Loïc Benoit Apr 02 '13 at 17:30
  • According to this [answer](http://stackoverflow.com/a/10012704/2193168), it might be an architecture problem. However, when using the file command, I get the same info for "mod_header" and "mod_xsendfile", that is: Mach-O 64-bit bundle x86_64. So it doesn't look like an architecture problem. – Loïc Benoit Apr 02 '13 at 18:35
  • Good news, Bitnami confirmed that they will include mod_xsendfile in the next release of the Bitnami MAPP stack. – Loïc Benoit Apr 04 '13 at 17:29
  • The next release of the Bitnami MAPP stack that includes mod_xsendfile should be somewhere around April 8 2013, according to the accepted answer on the [bitnami forum](http://answers.bitnami.org/questions/11701/how-to-compile-and-install-mod_xsendfile-on-mapp-stack/12238) – Loïc Benoit Apr 05 '13 at 18:58

1 Answers1

0

The question was "how to install mod_xsendfile on the Bitnami MAPPStack".

The answer is: Upgrade to the latest version, because Bitnami included it in the stack in response to my question and popular interest for mod_xsendfile. Also, you may read these additionnal instructions from Bitnami.