Skip to content

Commit

Permalink
Rename rp-pppoe.so plugin to pppoe.so
Browse files Browse the repository at this point in the history
Original out-of-tree rp-pppoe plugin for pppd software is still available
at website https://dianne.skoll.ca/projects/rp-pppoe/ and receives new
releases. The last update is from the June 2020.

Currently it is ambiguous if user is using original out-of-tree rp-pppoe
plugin or in-tree pppd's rp-pppoe plugin. These two plugins are different,
come from different sources but share same name.

Some users want to use original rp-pppoe plugin and not pppd's in-tree
rp-pppoe plugin. Also some distribution want to package both plugins,
pppd's in-tree and original rp-pppoe.

So for this reason and also because all other PPP over <something> plugins
have just pppo prefix, rename in-tree rp-pppoe.so plugin to just pppoe.so.

This will allow to distinguish and make it clear what is the original
rp-pppoe plugin and what is pppd's in-tree pppoe plugin.

When installing pppd create a compatibility symlink from pppoe.so to
rp-pppoe.so so nothing would be broken. This compatibility symlink may be
removed by Linux distribution which do not want to have compatibility with
the old name as before and rather use rp-pppoe.so name for original
rp-pppoe software.

Signed-off-by: Pali Rohár <pali@kernel.org>
  • Loading branch information
pali committed Dec 31, 2020
1 parent f1e3aa2 commit b2c36e6
Show file tree
Hide file tree
Showing 14 changed files with 15 additions and 16 deletions.
2 changes: 1 addition & 1 deletion README.pppoe
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ to connect to their ISP who is providing PPPoE based services.

4. Add the following line to /etc/ppp/options:

plugin rp-pppoe.so
plugin pppoe.so

The effect of this line is simply to make "eth0", "eth1",
....,"ethx" all valid device names for pppd (just like ttyS0,
Expand Down
2 changes: 1 addition & 1 deletion configure
Original file line number Diff line number Diff line change
Expand Up @@ -193,7 +193,7 @@ if [ -d "$ksrc" ]; then
echo "Creating Makefiles."
mkmkf $ksrc/Makefile.top Makefile
mkmkf $ksrc/Makedefs$compiletype Makedefs.com
for dir in pppd pppstats chat pppdump pppd/plugins pppd/plugins/rp-pppoe \
for dir in pppd pppstats chat pppdump pppd/plugins pppd/plugins/pppoe \
pppd/plugins/radius pppd/plugins/pppoatm \
pppd/plugins/pppol2tp; do
mkmkf $dir/Makefile.$makext $dir/Makefile
Expand Down
2 changes: 1 addition & 1 deletion pppd/plugins/Makefile.linux
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ BINDIR = $(DESTDIR)/sbin
MANDIR = $(DESTDIR)/share/man/man8
LIBDIR = $(DESTDIR)/lib/pppd/$(VERSION)

SUBDIRS := rp-pppoe pppoatm pppol2tp
SUBDIRS := pppoe pppoatm pppol2tp
# Uncomment the next line to include the radius authentication plugin
SUBDIRS += radius
PLUGINS := minconn.so passprompt.so passwordfd.so winbind.so
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -21,13 +21,11 @@ LIBDIR = $(DESTDIR)/lib/pppd/$(PPPDVERSION)
PPPDVERSION = $(shell awk -F '"' '/VERSION/ { print $$2; }' ../../patchlevel.h)

INSTALL = install

# Version is set ONLY IN THE MAKEFILE! Don't delete this!
RP_VERSION=3.8p
LN_S = ln -sf

COPTS=-O2 -g
CFLAGS=$(COPTS) -I../../../include '-DRP_VERSION="$(RP_VERSION)"'
all: rp-pppoe.so pppoe-discovery
CFLAGS=$(COPTS) -I../../../include
all: pppoe.so pppoe-discovery

pppoe-discovery: pppoe-discovery.o debug.o
$(CC) $(LDFLAGS) -o pppoe-discovery pppoe-discovery.o debug.o
Expand All @@ -38,12 +36,14 @@ pppoe-discovery.o: pppoe-discovery.c
debug.o: debug.c
$(CC) $(CFLAGS) -I../../.. -c -o debug.o debug.c

rp-pppoe.so: plugin.o discovery.o if.o common.o
$(CC) $(LDFLAGS) -o rp-pppoe.so -shared plugin.o discovery.o if.o common.o
pppoe.so: plugin.o discovery.o if.o common.o
$(CC) $(LDFLAGS) -o pppoe.so -shared plugin.o discovery.o if.o common.o

install: all
$(INSTALL) -d -m 755 $(LIBDIR)
$(INSTALL) -c -m 4550 rp-pppoe.so $(LIBDIR)
$(INSTALL) -c -m 4550 pppoe.so $(LIBDIR)
# Symlink for backward compatibility
$(LN_S) pppoe.so $(LIBDIR)/rp-pppoe.so
$(INSTALL) -d -m 755 $(BINDIR)
$(INSTALL) -c -m 555 pppoe-discovery $(BINDIR)

Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -399,8 +399,7 @@ plugin_init(void)

add_options(Options);

info("RP-PPPoE plugin version %s compiled against pppd %s",
RP_VERSION, VERSION);
info("PPPoE plugin from pppd %s", VERSION);
}

void pppoe_check_options(void)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -713,7 +713,7 @@ int main(int argc, char *argv[])
optarg, strerror(errno));
exit(1);
}
fprintf(conn->debugFile, "pppoe-discovery %s\n", RP_VERSION);
fprintf(conn->debugFile, "pppoe-discovery from pppd %s\n", VERSION);
break;
case 'I':
conn->ifName = xstrdup(optarg);
Expand Down Expand Up @@ -787,5 +787,5 @@ void usage(void)
" -U -- Use Host-Unique to allow multiple PPPoE sessions.\n"
" -W hexvalue -- Set the Host-Unique to the supplied hex string.\n"
" -h -- Print usage information.\n");
fprintf(stderr, "\nVersion " RP_VERSION "\n");
fprintf(stderr, "\npppoe-discovery from pppd " VERSION "\n");
}
File renamed without changes.
2 changes: 1 addition & 1 deletion pppd/pppd.8
Original file line number Diff line number Diff line change
Expand Up @@ -1204,7 +1204,7 @@ Use software flow control (i.e. XON/XOFF) to control the flow of data on
the serial port.
.SH PPPOE OPTIONS
To establish PPP link over Ethernet (PPPoE) it is needed to load pppd's
\fBplugin rp-pppoe.so\fR and then specify option \fBnic-\fIinterface\fR
\fBplugin pppoe.so\fR and then specify option \fBnic-\fIinterface\fR
instead of modem options \fIttyname\fR and \fIspeed\fR.
Recognized pppd's PPPoE options are:
.TP
Expand Down

0 comments on commit b2c36e6

Please sign in to comment.