diff options
author | Eric Andersen <andersen@codepoet.org> | 2002-05-03 09:52:44 +0000 |
---|---|---|
committer | Eric Andersen <andersen@codepoet.org> | 2002-05-03 09:52:44 +0000 |
commit | 757d7df4f4093fa2d0f8343b3fc80c47a11c7597 (patch) | |
tree | 1b5dfdd14868fb1c8c8e6649d9cbbe70906b7586 | |
parent | 82d5d3224c5f162229515e267f20f91ae3af58d9 (diff) |
Add in a sample of how to build a library vs uClibc
-rw-r--r-- | make/libglib12.mk | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/make/libglib12.mk b/make/libglib12.mk new file mode 100644 index 000000000..f9beb21f3 --- /dev/null +++ b/make/libglib12.mk @@ -0,0 +1,48 @@ +############################################################# +# +# libglib1.2 +# +############################################################# +LIBGLIB12_SOURCE:=glib-1.2.10.tar.gz +LIBGLIB12_SITE:=ftp://ftp.gtk.org/pub/gtk/v1.2 +LIBGLIB12_CAT:=zcat +LIBGLIB12_DIR:=$(BUILD_DIR)/glib-1.2.10 +LIBGLIB12_BINARY:=libglib-1.2.so.0.0.10 + +$(DL_DIR)/$(LIBGLIB12_SOURCE): + wget -P $(DL_DIR) $(LIBGLIB12_SITE)/$(LIBGLIB12_SOURCE) + +libglib12-source: $(DL_DIR)/$(LIBGLIB12_SOURCE) + +$(LIBGLIB12_DIR)/.unpacked: $(DL_DIR)/$(LIBGLIB12_SOURCE) + $(LIBGLIB12_CAT) $(DL_DIR)/$(LIBGLIB12_SOURCE) | tar -C $(BUILD_DIR) -xvf - + touch $(LIBGLIB12_DIR)/.unpacked + +$(LIBGLIB12_DIR)/.configured: $(LIBGLIB12_DIR)/.unpacked + (cd $(LIBGLIB12_DIR); rm -f config.cache; CC=$(TARGET_CC1) \ + ./configure --prefix=$(STAGING_DIR) --enable-shared \ + --host=$(ARCH)-pc-linux-gnu \ + ); + touch $(LIBGLIB12_DIR)/.configured + +$(LIBGLIB12_DIR)/.libs/$(LIBGLIB12_BINARY): $(LIBGLIB12_DIR)/.configured + $(MAKE) CC=$(TARGET_CC1) -C $(LIBGLIB12_DIR) + +$(STAGING_DIR)/lib/$(LIBGLIB12_BINARY): $(LIBGLIB12_DIR)/.libs/$(LIBGLIB12_BINARY) + $(MAKE) CC=$(TARGET_CC1) -C $(LIBGLIB12_DIR) install + +$(TARGET_DIR)/lib/$(LIBGLIB12_BINARY): $(STAGING_DIR)/lib/$(LIBGLIB12_BINARY) + cp -a $(STAGING_DIR)/lib/$(LIBGLIB12_BINARY) $(TARGET_DIR)/lib/ + cp -a $(STAGING_DIR)/lib/libglib.so $(TARGET_DIR)/lib/ + cp -a $(STAGING_DIR)/lib/libglib-1.2.so.0 $(TARGET_DIR)/lib/ + $(STRIP) --strip-unneeded $(TARGET_DIR)/lib/$(LIBGLIB12_BINARY) + +libglib12: uclibc $(TARGET_DIR)/lib/$(LIBGLIB12_BINARY) + +libglib12-clean: + rm -f $(TARGET_DIR)/lib/$(LIBGLIB12_BINARY) + -make -C $(LIBGLIB12_DIR) clean + +libglib12-dirclean: + rm -rf $(LIBGLIB12_DIR) + |