1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116
|
#!/usr/bin/make -f
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
# disable all threading
THREADS :=
ifeq (${DEB_HOST_ARCH},alpha)
COPTFLAGS := -O1
else
COPTFLAGS := -O2
endif
CONFFLAGS :=
build: build-stamp
build-stamp:
dh_testdir
#
# oo2c uses /usr/bin/libtool directly. Hmm...
# We need to use our own copy to fix the -rpath problem.
cp -av /usr/bin/libtool .
#-----------------------------------------------------------------------------
# Patch the generated libtool to avoid passing -rpath when linking,
# and to explicitly link libraries against the libraries they
# depend on.
sed < libtool > libtool-2 \
-e 's/^hardcode_libdir_flag_spec.*$$/hardcode_libdir_flag_spec=" -D__LIBTOOL_IS_A_FOOL__ "/'
mv libtool-2 libtool
chmod 755 libtool
#-----------------------------------------------------------------------------
autoconf
CFLAGS="-pipe -D_REENTRANT ${THREADS} -I/usr/include/gc" \
COPTFLAGS="${COPTFLAGS}" \
./configure --prefix=/usr ${CONFFLAGS} && \
$(MAKE)
touch build-stamp
clean:
dh_testdir
dh_testroot
rm -f build-stamp install-stamp
-$(MAKE) distclean
#
# Be prepared to remove the following commmand in the future!
rm -f libtool
dh_clean
install: install-stamp
install-stamp: build-stamp
dh_testdir
dh_testroot
dh_clean -k
dh_installdirs
$(MAKE) prefix=`pwd`/debian/tmp/usr install
dh_movefiles
touch install-stamp
# Build architecture-independent files here.
binary-indep: build install
# We have nothing to do by default.
# Build architecture-dependent files here.
binary-arch: build install
# dh_testversion
dh_testdir
dh_testroot
( cd debian/tmp && \
cp -av usr/lib/oo2c/o2-default.el etc/emacs/site-start.d/50oo2c.el )
dh_installdocs
dh_installexamples
dh_installmenu
# dh_installemacsen
dh_installchangelogs
# Move the man pages
(cd debian; for mandir in */usr/man; \
do \
NEWDIR=`echo $${mandir} | sed 's;man$$;share/man;'`; \
mv $${mandir} $${NEWDIR}; \
done)
dh_undocumented oobacktrace.1
# Move the info pages
(cd debian; for infodir in */usr/info; \
do \
NEWDIR=`echo $${infodir} | sed 's;info$$;share/info;'`; \
mv $${infodir} $${NEWDIR}; \
done)
dh_strip
dh_compress
dh_fixperms
dh_suidregister
dh_installdeb
dh_shlibdeps
dh_gencontrol
dh_makeshlibs
dh_md5sums
dh_builddeb
source diff:
@echo >&2 'source and diff are obsolete - use dpkg-source -b'; false
binary: binary-indep binary-arch
.PHONY: build clean install binary-indep binary-arch binary
|