# Note: some of the patches below were found in Gentoo : # http://gentoo.osuosl.org/distfiles/ (ppp-2.4.7-patches*) # Simply apply the following processing to convert all of them to -p1 : # for i in [0-9]*; do sed -i -e 's,^\(---\|+++\) pppd/,\1 ./pppd/,' $i; done # # The dhcpc patch has been built by extracting the original package found here: # http://www.netservers.co.uk/gpl/ppp-dhcpc.tgz # and then moving "dhcp" into "pppd/plugins/". # PATCH_LIST=" ppp-dhcpc.diff 02_all_make-vars.patch 03_all_use_internal_logwtmp.patch 04_all_mpls.patch 06_all_killaddr-smarter.patch 08_all_wait-children.patch 10_all_defaultgateway.patch 12_all_linkpidfile.patch 16_all_auth-fail.patch 18_all_defaultmetric.patch 20_all_dev-ppp.patch 24_all_passwordfd-read-early.patch 26_all_pppd-usepeerwins.patch 28_all_connect-errors.patch 30_all_Makefile.patch 32_all_pado-timeout.patch 34_all_lcp-echo-adaptive.patch 85_all_dhcp-make-vars.patch 86_all_dhcp-sys_error_to_strerror.patch pppoatm-needs-libatm.diff " # unused: 80_all_eaptls-mppe-0.997.patch FILE_LIST= SRC_FETCH_METHOD=ftp SRC_FETCH_PATH=ftp://ftp.samba.org/pub/ppp/ppp-${PKGVER}.tar.gz MAKEDEPENDS='libpcap-*:::*.h *.a' # format : # MAKEDEPENDS='packagename:versfx:architecture:globbing' # # exemple : # MAKEDEPENDS='tplparser-0local-flx0.0:albdev:i586:*.a *.h' function do_config { CFLAGS="$GCC_OPT_SMALL $GCC_ARCH_SMALL $GCC_CPU_SMALL" \ ./configure --prefix=/usr --sysconfdir=/etc } function do_compile_only { # Warning: some incremental variables need to be pre-initialized as # environment variables : COPTS, LDFLAGS. COPTS="$GCC_OPT_SMALL $GCC_ARCH_SMALL $GCC_CPU_SMALL" \ LDFLAGS="" \ $FLXPMAKE CC=${CC} INSTROOT="" } function do_prepack { mkdir -p $ROOTDIR/etc/ppp $ROOTDIR/usr $EXAMPLEDIR/pppd/$PKGVER $FLXMAKE install INSTROOT=$ROOTDIR DESTDIR=$ROOTDIR/usr mv $ROOTDIR/etc/ $EXAMPLEDIR/pppd/$PKGVER/ cp $PKGDIR/add-ons/* $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/ sed -e "s/%%PKGVER%%/$PKGVER/g" \ < $PKGDIR/add-ons/adsl > $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/adsl echo '#"account@provider" * "password"' >> $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/pap-secrets echo '#"account@provider" * "password"' >> $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/chap-secrets mkdir -p $ROOTDIR/sbin/init.d && \ mv $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/adsl $ROOTDIR/sbin/init.d : > $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/options set_default_perm $ROOTDIR set_perm root:adm 740 $ROOTDIR/usr/lib/pppd/$PKGVER/* mkdir -p $ROOTDIR/etc/ppp set_perm root:adm 750 $ROOTDIR/etc/ppp set_perm root:man 755 $EXAMPLEDIR/pppd/$PKGVER/etc/ppp/{*ip*,wshaper*} }