[rtems commit] mghttpd: Requires POSIX to build server and tests

Joel Sherrill joel at rtems.org
Wed Oct 3 19:50:02 UTC 2012


Module:    rtems
Branch:    master
Commit:    cb7b57e174d7a559af3ec910a99e0538cc9f99b7
Changeset: http://git.rtems.org/rtems/commit/?id=cb7b57e174d7a559af3ec910a99e0538cc9f99b7

Author:    Joel Sherrill <joel.sherrill at oarcorp.com>
Date:      Wed Oct  3 11:09:32 2012 -0500

mghttpd: Requires POSIX to build server and tests

Formerly, mghttpd was conditional only on networking being
enabled. It uses on pthread and must also be conditional
on POSIX threads support being enabled.

---

 cpukit/mghttpd/Makefile.am       |    2 ++
 cpukit/mghttpd/preinstall.am     |    2 ++
 testsuites/libtests/Makefile.am  |    2 ++
 testsuites/libtests/configure.ac |    2 ++
 4 files changed, 8 insertions(+), 0 deletions(-)

diff --git a/cpukit/mghttpd/Makefile.am b/cpukit/mghttpd/Makefile.am
index e4ed9fd..78af78d 100644
--- a/cpukit/mghttpd/Makefile.am
+++ b/cpukit/mghttpd/Makefile.am
@@ -1,6 +1,7 @@
 include $(top_srcdir)/automake/compile.am
 
 if LIBNETWORKING
+if HAS_PTHREADS
 include_mghttpddir = $(includedir)/mghttpd
 
 project_lib_LIBRARIES = libmghttpd.a
@@ -11,6 +12,7 @@ libmghttpd_a_CPPFLAGS += -DNO_SSL -DNO_POPEN -DNO_CGI
 libmghttpd_a_SOURCES = mongoose.c mongoose.h
 include_mghttpd_HEADERS = mongoose.h
 endif
+endif
 
 include $(srcdir)/preinstall.am
 include $(top_srcdir)/automake/local.am
diff --git a/cpukit/mghttpd/preinstall.am b/cpukit/mghttpd/preinstall.am
index aa246f0..305a914 100644
--- a/cpukit/mghttpd/preinstall.am
+++ b/cpukit/mghttpd/preinstall.am
@@ -24,6 +24,7 @@ $(PROJECT_LIB)/$(dirstamp):
 PREINSTALL_DIRS += $(PROJECT_LIB)/$(dirstamp)
 
 if LIBNETWORKING
+if HAS_PTHREADS
 $(PROJECT_INCLUDE)/mghttpd/$(dirstamp):
 	@$(MKDIR_P) $(PROJECT_INCLUDE)/mghttpd
 	@: > $(PROJECT_INCLUDE)/mghttpd/$(dirstamp)
@@ -37,3 +38,4 @@ $(PROJECT_INCLUDE)/mghttpd/mongoose.h: mongoose.h $(PROJECT_INCLUDE)/mghttpd/$(d
 	$(INSTALL_DATA) $< $(PROJECT_INCLUDE)/mghttpd/mongoose.h
 PREINSTALL_FILES += $(PROJECT_INCLUDE)/mghttpd/mongoose.h
 endif
+endif
diff --git a/testsuites/libtests/Makefile.am b/testsuites/libtests/Makefile.am
index 69f4e8d..57f965b 100644
--- a/testsuites/libtests/Makefile.am
+++ b/testsuites/libtests/Makefile.am
@@ -20,7 +20,9 @@ SUBDIRS += bspcmdline01 cpuuse devfs01 devfs02 devfs03 devfs04 \
     mouse01
 
 if NETTESTS
+if HAS_POSIX
 SUBDIRS += mghttpd01
+endif
 SUBDIRS += ftp01
 SUBDIRS += syscall01
 endif
diff --git a/testsuites/libtests/configure.ac b/testsuites/libtests/configure.ac
index a29c7f8..b40055c 100644
--- a/testsuites/libtests/configure.ac
+++ b/testsuites/libtests/configure.ac
@@ -27,6 +27,7 @@ RTEMS_CANONICALIZE_TOOLS
 RTEMS_CHECK_CUSTOM_BSP(RTEMS_BSP)
 RTEMS_CHECK_CXX(RTEMS_BSP)
 RTEMS_CHECK_CPUOPTS([RTEMS_NETWORKING])
+RTEMS_CHECK_CPUOPTS([RTEMS_POSIX_API])
 
 AC_PROG_LN_S
 AC_PATH_PROG([PAX],[pax])
@@ -38,6 +39,7 @@ AM_CONDITIONAL(TARTESTS,test "$as_ln_s" = "ln -s" && test -n "$PAX")
 AM_CONDITIONAL(HAS_CXX,test "$rtems_cv_HAS_CPLUSPLUS" = "yes")
 AM_CONDITIONAL([HAS_COMPLEX],[test "$ac_cv_header_complex_h" = yes])
 AM_CONDITIONAL(NETTESTS,test "$rtems_cv_RTEMS_NETWORKING" = "yes")
+AM_CONDITIONAL(HAS_POSIX,test x"${rtems_cv_RTEMS_POSIX_API}" = x"yes")
 
 # Explicitly list all Makefiles here
 AC_CONFIG_FILES([Makefile




More information about the vc mailing list