diff options
author | Eric Andersen <andersen@codepoet.org> | 2002-05-23 19:21:23 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2002-05-23 19:21:23 +0000 |
commit | 6387962e30c205246a5615b4d202a080601f93d0 (patch) | |
tree | d5b1427e4e5408eaefacb7adc1ebc7cd9ffc28c6 /make/newt.mk | |
parent | 2fcdc3786da919cb034e976b67b15250cd3cbdaf (diff) |
Add some toys for people to play with
Diffstat (limited to 'make/newt.mk')
-rw-r--r-- | make/newt.mk | 57 |
1 files changed, 57 insertions, 0 deletions
diff --git a/make/newt.mk b/make/newt.mk new file mode 100644 index 000000000..3075dd8b2 --- /dev/null +++ b/make/newt.mk @@ -0,0 +1,57 @@ +############################################################# +# +# newt +# +############################################################# +NEWT_SOURCE=newt_0.50.17.orig.tar.gz +NEWT_SITE=http://ftp.debian.org/debian/pool/main/n/newt +NEWT_DIR=$(BUILD_DIR)/newt-0.50.17 +NEWT_PATCH=$(SOURCE_DIR)/newt.patch +ifeq ($(strip $(BUILD_WITH_LARGEFILE)),true) +NEWT_CFLAGS="-Os -g -fPIC -D_FILE_OFFSET_BITS=64 -D__USE_FILE_OFFSET64" +else +NEWT_CFLAGS="-Os -g -fPIC" +endif + +$(DL_DIR)/$(NEWT_SOURCE): + wget -P $(DL_DIR) $(NEWT_SITE)/$(NEWT_SOURCE) + +$(NEWT_DIR)/.source: $(DL_DIR)/$(NEWT_SOURCE) $(NEWT_PATCH) + zcat $(DL_DIR)/$(NEWT_SOURCE) | tar -C $(BUILD_DIR) -xvf - + cat $(NEWT_PATCH) | patch -p1 -d $(NEWT_DIR) + (cd $(NEWT_DIR); autoconf); + touch $(NEWT_DIR)/.source; + +$(NEWT_DIR)/.configured: $(NEWT_DIR)/.source + (cd $(NEWT_DIR); rm -rf config.cache; CC=$(TARGET_CC1) \ + ./configure --shared --prefix=/usr --exec_prefix=$(STAGING_DIR)/usr/bin \ + --libdir=$(STAGING_DIR)/lib --includedir=$(STAGING_DIR)/include \ + --host=$(ARCH)-pc-linux-gnu); + touch $(NEWT_DIR)/.configured; + +$(NEWT_DIR)/libnewt.so.0.50.17: $(NEWT_DIR)/.configured + $(MAKE) CFLAGS=$(NEWT_CFLAGS) CC=$(TARGET_CC1) -C $(NEWT_DIR) + touch -c $(NEWT_DIR)/libnewt.so.0.50.17 + +$(STAGING_DIR)/lib/libnewt.so.0.50.17: $(NEWT_DIR)/libnewt.so.0.50.17 + cp -a $(NEWT_DIR)/libnewt.a $(STAGING_DIR)/lib; + cp -a $(NEWT_DIR)/newt.h $(STAGING_DIR)/include; + cp -a $(NEWT_DIR)/libnewt.so* $(STAGING_DIR)/lib; + (cd $(STAGING_DIR)/lib; ln -fs libnewt.so.0.50.17 libnewt.so); + (cd $(STAGING_DIR)/lib; ln -fs libnewt.so.0.50.17 libnewt.so.0.50); + touch -c $(STAGING_DIR)/lib/libnewt.so.0.50.17 + +$(TARGET_DIR)/lib/libnewt.so.0.50.17: $(STAGING_DIR)/lib/libnewt.so.0.50.17 + cp -a $(STAGING_DIR)/lib/libnewt.so* $(TARGET_DIR)/lib; + -$(STRIP) --strip-unneeded $(TARGET_DIR)/lib/libnewt.so* + touch -c $(TARGET_DIR)/lib/libnewt.so.0.50.17 + +newt: uclibc slang $(TARGET_DIR)/lib/libnewt.so.0.50.17 + +newt-clean: + rm -f $(TARGET_DIR)/lib/libnewt.so* + -make -C $(NEWT_DIR) clean + +newt-dirclean: slang-dirclean + rm -rf $(NEWT_DIR) + |