2006-01-23 20:49:38 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# libcgi
|
|
|
|
#
|
|
|
|
#############################################################
|
|
|
|
LIBCGI_VERSION:=1.0
|
|
|
|
LIBCGI_SOURCE:=libcgi-$(LIBCGI_VERSION).tar.gz
|
|
|
|
LIBCGI_SITE:=http://$(BR2_SOURCEFORGE_MIRROR).dl.sourceforge.net/sourceforge/libcgi
|
|
|
|
LIBCGI_DIR:=$(BUILD_DIR)/libcgi-$(LIBCGI_VERSION)
|
2007-07-16 11:32:07 +02:00
|
|
|
LIBCGI_LIBRARY:=src/libcgi.so
|
2007-07-16 21:03:46 +02:00
|
|
|
LIBCGI_DESTDIR:=usr/lib
|
|
|
|
LIBCGI_TARGET_LIBRARY=$(LIBCGI_DESTDIR)/libcgi.so
|
2006-01-23 20:49:38 +01:00
|
|
|
|
|
|
|
$(DL_DIR)/$(LIBCGI_SOURCE):
|
|
|
|
$(WGET) -P $(DL_DIR) $(LIBCGI_SITE)/$(LIBCGI_SOURCE)
|
|
|
|
|
|
|
|
$(LIBCGI_DIR)/.source: $(DL_DIR)/$(LIBCGI_SOURCE)
|
2006-10-01 17:17:52 +02:00
|
|
|
$(ZCAT) $(DL_DIR)/$(LIBCGI_SOURCE) | tar -C $(BUILD_DIR) $(TAR_OPTIONS) -
|
2006-12-12 14:16:31 +01:00
|
|
|
toolchain/patch-kernel.sh $(LIBCGI_DIR) package/libcgi/ libcgi\*.patch
|
2006-01-23 20:49:38 +01:00
|
|
|
touch $(LIBCGI_DIR)/.source
|
|
|
|
|
|
|
|
$(LIBCGI_DIR)/.configured: $(LIBCGI_DIR)/.source
|
2007-09-25 14:34:09 +02:00
|
|
|
(cd $(LIBCGI_DIR); rm -f config.cache; \
|
2006-01-23 20:49:38 +01:00
|
|
|
$(TARGET_CONFIGURE_OPTS) \
|
2007-06-27 14:01:27 +02:00
|
|
|
$(TARGET_CONFIGURE_ARGS) \
|
2006-01-23 20:49:38 +01:00
|
|
|
./configure \
|
2007-09-25 14:34:09 +02:00
|
|
|
--target=$(GNU_TARGET_NAME) \
|
|
|
|
--host=$(GNU_TARGET_NAME) \
|
|
|
|
--build=$(GNU_HOST_NAME) \
|
|
|
|
--prefix=/usr \
|
|
|
|
--exec-prefix=/usr \
|
|
|
|
--bindir=/usr/bin \
|
|
|
|
--sbindir=/usr/sbin \
|
|
|
|
--libdir=/lib \
|
|
|
|
--libexecdir=/$(LIBCGI_DESTDIR) \
|
|
|
|
--sysconfdir=/etc \
|
|
|
|
--datadir=/usr/share \
|
|
|
|
--localstatedir=/var \
|
|
|
|
--includedir=/include \
|
|
|
|
--mandir=/usr/man \
|
|
|
|
--infodir=/usr/info \
|
2007-08-21 21:20:18 +02:00
|
|
|
)
|
|
|
|
touch $(LIBCGI_DIR)/.configured
|
2006-01-23 20:49:38 +01:00
|
|
|
|
|
|
|
$(LIBCGI_DIR)/$(LIBCGI_LIBRARY): $(LIBCGI_DIR)/.configured
|
|
|
|
$(MAKE) CC=$(TARGET_CC) -C $(LIBCGI_DIR)
|
|
|
|
|
2007-07-16 21:03:46 +02:00
|
|
|
$(STAGING_DIR)/$(LIBCGI_TARGET_LIBRARY): $(LIBCGI_DIR)/$(LIBCGI_LIBRARY)
|
2007-01-14 04:52:21 +01:00
|
|
|
$(MAKE) DESTDIR=$(STAGING_DIR) -C $(LIBCGI_DIR) install
|
2007-07-16 21:03:46 +02:00
|
|
|
touch -c $@
|
2006-12-12 14:16:31 +01:00
|
|
|
|
2007-07-16 11:32:07 +02:00
|
|
|
$(TARGET_DIR)/$(LIBCGI_TARGET_LIBRARY): $(STAGING_DIR)/$(LIBCGI_TARGET_LIBRARY)
|
2007-07-16 21:03:46 +02:00
|
|
|
cp -dpf $<* $(TARGET_DIR)/$(LIBCGI_DESTDIR)
|
2006-01-23 20:49:38 +01:00
|
|
|
|
|
|
|
libcgi: uclibc $(TARGET_DIR)/$(LIBCGI_TARGET_LIBRARY)
|
|
|
|
|
|
|
|
libcgi-source: $(DL_DIR)/$(LIBCGI_SOURCE)
|
|
|
|
|
|
|
|
libcgi-clean:
|
2007-07-16 21:03:46 +02:00
|
|
|
rm -f $(TARGET_DIR)/$(LIBCGI_TARGET_LIBRARY)*
|
2006-01-23 20:49:38 +01:00
|
|
|
-$(MAKE) -C $(LIBCGI_DIR) clean
|
|
|
|
|
|
|
|
libcgi-dirclean:
|
|
|
|
rm -rf $(LIBCGI_DIR)
|
|
|
|
|
2007-08-20 19:21:16 +02:00
|
|
|
.PHONY: libcgi
|
2006-01-23 20:49:38 +01:00
|
|
|
#############################################################
|
|
|
|
#
|
|
|
|
# Toplevel Makefile options
|
|
|
|
#
|
|
|
|
#############################################################
|
|
|
|
ifeq ($(strip $(BR2_PACKAGE_LIBCGI)),y)
|
2006-12-12 14:16:31 +01:00
|
|
|
TARGETS+=libcgi
|
2006-01-23 20:49:38 +01:00
|
|
|
endif
|