| 1 | # $Id: Makefile 3622 2006-04-12 00:34:26Z nico $
|
|---|
| 2 |
|
|---|
| 3 | include $(TOPDIR)/rules.mk
|
|---|
| 4 |
|
|---|
| 5 | PKG_NAME:=libol
|
|---|
| 6 | PKG_VERSION:=0.3.18
|
|---|
| 7 | PKG_RELEASE:=1
|
|---|
| 8 | PKG_MD5SUM:=cbadf4b7ea276dfa85acc38a1cc5ff17
|
|---|
| 9 |
|
|---|
| 10 | PKG_SOURCE_URL:=http://www.balabit.com/downloads/libol/0.3
|
|---|
| 11 | PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
|---|
| 12 |
|
|---|
| 13 |
|
|---|
| 14 | include $(TOPDIR)/package/rules.mk
|
|---|
| 15 |
|
|---|
| 16 | $(eval $(call PKG_template,LIBOL,libol,$(PKG_VERSION)-$(PKG_RELEASE),$(ARCH)))
|
|---|
| 17 |
|
|---|
| 18 | $(WRKBUILD)/.configured:
|
|---|
| 19 | (cd $(WRKBUILD); rm -rf config.{cache,status} ; \
|
|---|
| 20 | $(TARGET_CONFIGURE_OPTS) \
|
|---|
| 21 | CFLAGS="$(TARGET_CFLAGS)" \
|
|---|
| 22 | CPPFLAGS="-I$(STAGING_DIR)/usr/include -I$(STAGING_DIR)/include" \
|
|---|
| 23 | LDFLAGS="-L$(STAGING_DIR)/usr/lib -L$(STAGING_DIR)/lib" \
|
|---|
| 24 | ./configure \
|
|---|
| 25 | --target=$(GNU_TARGET_NAME) \
|
|---|
| 26 | --host=$(GNU_TARGET_NAME) \
|
|---|
| 27 | --build=$(GNU_HOST_NAME) \
|
|---|
| 28 | --program-prefix="" \
|
|---|
| 29 | --program-suffix="" \
|
|---|
| 30 | --prefix=/usr \
|
|---|
| 31 | --exec-prefix=/usr \
|
|---|
| 32 | --bindir=/usr/bin \
|
|---|
| 33 | --datadir=/usr/share \
|
|---|
| 34 | --includedir=/usr/include \
|
|---|
| 35 | --infodir=/usr/share/info \
|
|---|
| 36 | --libdir=/usr/lib \
|
|---|
| 37 | --libexecdir=/usr/lib \
|
|---|
| 38 | --localstatedir=/var \
|
|---|
| 39 | --mandir=/usr/share/man \
|
|---|
| 40 | --sbindir=/usr/sbin \
|
|---|
| 41 | --sysconfdir=/etc \
|
|---|
| 42 | --enable-largefile \
|
|---|
| 43 | --disable-nls \
|
|---|
| 44 | --enable-shared \
|
|---|
| 45 | --enable-static \
|
|---|
| 46 | )
|
|---|
| 47 | touch $@
|
|---|
| 48 |
|
|---|
| 49 | $(WRKBUILD)/.built:
|
|---|
| 50 | rm -rf $(WRKINST)
|
|---|
| 51 | mkdir -p $(WRKINST)
|
|---|
| 52 | # pass CFLAGS again to override -O2 set by configure
|
|---|
| 53 | $(MAKE) -C $(WRKBUILD) \
|
|---|
| 54 | CFLAGS="$(TARGET_CFLAGS)" \
|
|---|
| 55 | DESTDIR="$(WRKINST)" \
|
|---|
| 56 | all install
|
|---|
| 57 | touch $@
|
|---|
| 58 |
|
|---|
| 59 | $(IPKG_LIBOL):
|
|---|
| 60 | install -d -m0755 $(IDIR_LIBOL)/usr/lib
|
|---|
| 61 | $(CP) $(WRKINST)/usr/lib/libol.so.* $(IDIR_LIBOL)/usr/lib/
|
|---|
| 62 | $(RSTRIP) $(IDIR_LIBOL)
|
|---|
| 63 | $(IPKG_BUILD) $(IDIR_LIBOL) $(PACKAGE_DIR)
|
|---|
| 64 |
|
|---|
| 65 | $(STAGING_DIR)/usr/lib/libol.so: $(WRKBUILD)/.built
|
|---|
| 66 | mkdir -p $(STAGING_DIR)/usr/bin
|
|---|
| 67 | $(CP) $(WRKINST)/usr/bin/libol-config $(STAGING_DIR)/usr/bin/
|
|---|
| 68 | mkdir -p $(STAGING_DIR)/usr/include
|
|---|
| 69 | $(CP) $(WRKINST)/usr/include/libol $(STAGING_DIR)/usr/include/
|
|---|
| 70 | mkdir -p $(STAGING_DIR)/usr/lib
|
|---|
| 71 | $(CP) $(WRKINST)/usr/lib/libol.{*a,so*} $(STAGING_DIR)/usr/lib/
|
|---|
| 72 | touch $@
|
|---|
| 73 |
|
|---|
| 74 | install-dev: $(STAGING_DIR)/usr/lib/libol.so
|
|---|
| 75 |
|
|---|
| 76 | uninstall-dev:
|
|---|
| 77 | rm -rf \
|
|---|
| 78 | $(STAGING_DIR)/usr/bin/libol-config \
|
|---|
| 79 | $(STAGING_DIR)/usr/include/libol \
|
|---|
| 80 | $(STAGING_DIR)/usr/lib/libol.{*a,so*} \
|
|---|
| 81 |
|
|---|
| 82 | compile-targets: install-dev
|
|---|
| 83 | clean-targets: uninstall-dev
|
|---|
| 84 |
|
|---|