Skip to contentSkip to conversation

rp-pppoe: install default conf file

PATCH New Ryan Coe 4 participants 11 messages Dec 2, 2014 – Dec 3, 2014

lore
Share & tools
lore

Ryan Coe

author
#0 lore raw

PATCH 1/2 rp-pppoe: install default conf file

---
 package/rp-pppoe/rp-pppoe.mk | 2 ++
 1 file changed, 2 insertions(+)
package/rp-pppoe/rp-pppoe.mk +2 -0
index 4e17f2d..70b4437 100644
@@ -18,6 +18,8 @@ RP_PPPOE_CONF_ENV = \
 	PPPD_H=$(PPPD_DIR)/pppd/pppd.h
 
 define RP_PPPOE_INSTALL_TARGET_CMDS
+	$(INSTALL) -D -m 0644 $(@D)/configs/pppoe.conf \
+		$(TARGET_DIR)/etc/ppp/pppoe.conf
 	for ff in $(RP_PPPOE_TARGET_FILES); do \
 		$(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
 	done
Signature · 1 line
2.2.0
author
#1 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

---
 package/rp-pppoe/rp-pppoe.mk | 5 +++++
 1 file changed, 5 insertions(+)
package/rp-pppoe/rp-pppoe.mk +5 -0
index 70b4437..9c3e3e4 100644
@@ -11,6 +11,8 @@ RP_PPPOE_LICENSE_FILES = doc/LICENSE
 RP_PPPOE_DEPENDENCIES = pppd
 RP_PPPOE_SUBDIR = src
 RP_PPPOE_TARGET_FILES = pppoe pppoe-server pppoe-relay pppoe-sniff
+RP_PPPOE_TARGET_SCRIPTS = pppoe-connect pppoe-init pppoe-setup pppoe-start \
+	pppoe-stop
 RP_PPPOE_MAKE_OPTS = PLUGIN_DIR=/usr/lib/pppd/$(PPPD_VERSION)
 RP_PPPOE_CONF_OPTS = --disable-debugging
 RP_PPPOE_CONF_ENV = \
@@ -23,6 +25,9 @@ define RP_PPPOE_INSTALL_TARGET_CMDS
 	for ff in $(RP_PPPOE_TARGET_FILES); do \
 		$(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
 	done
+	for ff in $(RP_PPPOE_TARGET_SCRIPTS); do \
+		$(INSTALL) -m 0755 $(@D)/scripts/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
+	done
 endef
 
 $(eval $(autotools-package))
Signature · 1 line
2.2.0
#2 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

Ryan,

Quoted 19 lines · Ryan Coe
---
 package/rp-pppoe/rp-pppoe.mk | 5 +++++
 1 file changed, 5 insertions(+)
package/rp-pppoe/rp-pppoe.mk +2 -0
index 70b4437..9c3e3e4 100644
@@ -11,6 +11,8 @@ RP_PPPOE_LICENSE_FILES = doc/LICENSE
 RP_PPPOE_DEPENDENCIES = pppd
 RP_PPPOE_SUBDIR = src
 RP_PPPOE_TARGET_FILES = pppoe pppoe-server pppoe-relay pppoe-sniff
+RP_PPPOE_TARGET_SCRIPTS = pppoe-connect pppoe-init pppoe-setup pppoe-start \
+       pppoe-stop
 RP_PPPOE_MAKE_OPTS = PLUGIN_DIR=/usr/lib/pppd/$(PPPD_VERSION)
 RP_PPPOE_CONF_OPTS = --disable-debugging
 RP_PPPOE_CONF_ENV = \

package/rp-pppoe/rp-pppoe.mk define RP_PPPOE_INSTALL_TARGET_CMDS · line 30

Quoted 6 lines
package/rp-pppoe/rp-pppoe.mk +3 -0
@@ -23,6 +25,9 @@ define RP_PPPOE_INSTALL_TARGET_CMDS
        for ff in $(RP_PPPOE_TARGET_FILES); do \
                $(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
        done
+       for ff in $(RP_PPPOE_TARGET_SCRIPTS); do \
+               $(INSTALL) -m 0755 $(@D)/scripts/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
+       done

Thanks for submitting this, I was about to work on a similar patch set!

Quoted 10 lines
package/rp-pppoe/rp-pppoe.mk +0 -1
 endef
 
 $(eval $(autotools-package))
--

2.2.0

_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

Signature · 8 lines
Matthew L Weber / Pr Software Engineer
Airborne Information Systems / Security Systems and Software
MS 131-100, C Ave NE, Cedar Rapids, IA, 52498, USA
www.rockwellcollins.com

Note: Any Export License Required Information and License Restricted
Third Party Intellectual Property (TPIP) content must be encrypted and
sent to matthew.weber at corp.rockwellcollins.com.
#3 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

In reply to Ryan Coe

Dear Ryan Coe,

Quoted 10 lines · Ryan Coe
---
 package/rp-pppoe/rp-pppoe.mk | 5 +++++
 1 file changed, 5 insertions(+)
package/rp-pppoe/rp-pppoe.mk +0 -0
index 70b4437..9c3e3e4 100644

package/rp-pppoe/rp-pppoe.mk RP_PPPOE_LICENSE_FILES = doc/LICENSE · line 15

Quoted 5 lines
package/rp-pppoe/rp-pppoe.mk +2 -0
@@ -11,6 +11,8 @@ RP_PPPOE_LICENSE_FILES = doc/LICENSE
 RP_PPPOE_DEPENDENCIES = pppd
 RP_PPPOE_SUBDIR = src
 RP_PPPOE_TARGET_FILES = pppoe pppoe-server pppoe-relay pppoe-sniff
+RP_PPPOE_TARGET_SCRIPTS = pppoe-connect pppoe-init pppoe-setup pppoe-start \
+	pppoe-stop

Any reason why we need a new variable instead of adding new values to RP_PPPOE_TARGET_FILES ?

package/rp-pppoe/rp-pppoe.mk define RP_PPPOE_INSTALL_TARGET_CMDS · line 30

Quoted 7 lines
package/rp-pppoe/rp-pppoe.mk +3 -0
@@ -23,6 +25,9 @@ define RP_PPPOE_INSTALL_TARGET_CMDS
 	for ff in $(RP_PPPOE_TARGET_FILES); do \
 		$(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
 	done
+	for ff in $(RP_PPPOE_TARGET_SCRIPTS); do \
+		$(INSTALL) -m 0755 $(@D)/scripts/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
+	done

Both variables do the same thing.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#4 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

Quoted 23 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Thomas" == Thomas Petazzoni <[email protected]> writes:

Dear Ryan Coe,

Quoted 13 lines · Ryan Coe

---
package/rp-pppoe/rp-pppoe.mk | 5 +++++

1 file changed, 5 insertions(+)
package/rp-pppoe/rp-pppoe.mk +0 -0
index 70b4437..9c3e3e4 100644
@@ -11,6 +11,8 @@ RP_PPPOE_LICENSE_FILES = doc/LICENSE

RP_PPPOE_DEPENDENCIES = pppd
RP_PPPOE_SUBDIR = src
RP_PPPOE_TARGET_FILES = pppoe pppoe-server pppoe-relay pppoe-sniff

package/rp-pppoe/rp-pppoe.mk RP_PPPOE_LICENSE_FILES = doc/LICENSE · line 15

Quoted 2 lines
package/rp-pppoe/rp-pppoe.mk +2 -0
+RP_PPPOE_TARGET_SCRIPTS = pppoe-connect pppoe-init pppoe-setup pppoe-start \
+	pppoe-stop

Any reason why we need a new variable instead of adding new values to RP_PPPOE_TARGET_FILES ?

Quoted 9 lines

package/rp-pppoe/rp-pppoe.mk define RP_PPPOE_INSTALL_TARGET_CMDS · line 30

Quoted 7 lines
package/rp-pppoe/rp-pppoe.mk +0 -0
@@ -23,6 +25,9 @@ define RP_PPPOE_INSTALL_TARGET_CMDS
 for ff in $(RP_PPPOE_TARGET_FILES); do \
 $(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \

done

package/rp-pppoe/rp-pppoe.mk +3 -0
+	for ff in $(RP_PPPOE_TARGET_SCRIPTS); do \
+		$(INSTALL) -m 0755 $(@D)/scripts/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
+	done

Both variables do the same thing.

No, they copy from two different subdirs?

Signature · 1 line
Bye, Peter Korsgaard
#5 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

Dear Peter Korsgaard,

Quoted 11 lines · Peter Korsgaard
Quoted 9 lines

package/rp-pppoe/rp-pppoe.mk define RP_PPPOE_INSTALL_TARGET_CMDS · line 30

Quoted 7 lines
package/rp-pppoe/rp-pppoe.mk +0 -0
@@ -23,6 +25,9 @@ define RP_PPPOE_INSTALL_TARGET_CMDS
 for ff in $(RP_PPPOE_TARGET_FILES); do \
 $(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \

done

package/rp-pppoe/rp-pppoe.mk +3 -0
+	for ff in $(RP_PPPOE_TARGET_SCRIPTS); do \
+		$(INSTALL) -m 0755 $(@D)/scripts/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
+	done

Both variables do the same thing.

No, they copy from two different subdirs?

Gaah, my bad, I overlooked that. Indeed, both variables are needed then. So the patch looks OK to me.

Sorry for the noise :/

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#6 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

Dear Thomas Petazzoni,

Quoted 11 lines · Thomas Petazzoni

Dear Peter Korsgaard,

Quoted 8 lines · Peter Korsgaard
Quoted 7 lines
Quoted 7 lines
package/rp-pppoe/rp-pppoe.mk +0 -0
@@ -23,6 +25,9 @@ define RP_PPPOE_INSTALL_TARGET_CMDS
 for ff in $(RP_PPPOE_TARGET_FILES); do \
 $(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \

done

package/rp-pppoe/rp-pppoe.mk +3 -0
+	for ff in $(RP_PPPOE_TARGET_SCRIPTS); do \
+		$(INSTALL) -m 0755 $(@D)/scripts/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
+	done
Quoted 8 lines
Quoted 3 lines
Quoted 1 line

Both variables do the same thing.

No, they copy from two different subdirs?

Gaah, my bad, I overlooked that. Indeed, both variables are needed then. So the patch looks OK to me.

Sorry for the noise :/

On a second thought, we could do:

RP_PPPOE_TARGET_FILES = src/foo src/bar scripts/baz scripts/bleh

and then do:

	for ff in $(RP_PPPOE_TARGET_FILES); do \
		$(INSTALL) -m 0755 $(@D)/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
	done

Not sure it matters much, though.

Thomas

Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons
Embedded Linux, Kernel and Android engineering
http://free-electrons.com
#7 lore raw

PATCH 2/2 rp-pppoe: install helper scripts

Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line

"Thomas" == Thomas Petazzoni <[email protected]> writes:

Hi,

Quoted 9 lines

On a second thought, we could do:

RP_PPPOE_TARGET_FILES = src/foo src/bar scripts/baz scripts/bleh

and then do:

	for ff in $(RP_PPPOE_TARGET_FILES); do \
		$(INSTALL) -m 0755 $(@D)/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
	done

Then you whould need to strip the directory part of $$ff for the destination to not end up in $(TARGET_DIR)/usr/sbin/src/foo.

Quoted 1 line

Not sure it matters much, though.

I think keeping it in two loops is a bit more readable.

Signature · 2 lines
Venlig hilsen,
Peter Korsgaard 
#9 lore raw

PATCH 1/2 rp-pppoe: install default conf file

In reply to Ryan Coe

Ryan,

Quoted 10 lines · Ryan Coe
---
 package/rp-pppoe/rp-pppoe.mk | 2 ++
 1 file changed, 2 insertions(+)
package/rp-pppoe/rp-pppoe.mk +0 -0
index 4e17f2d..70b4437 100644

package/rp-pppoe/rp-pppoe.mk RP_PPPOE_CONF_ENV = \ · line 22

Quoted 5 lines
package/rp-pppoe/rp-pppoe.mk +2 -0
@@ -18,6 +18,8 @@ RP_PPPOE_CONF_ENV = \
        PPPD_H=$(PPPD_DIR)/pppd/pppd.h
 
 define RP_PPPOE_INSTALL_TARGET_CMDS
+       $(INSTALL) -D -m 0644 $(@D)/configs/pppoe.conf \
+               $(TARGET_DIR)/etc/ppp/pppoe.conf
Quoted 10 lines
package/rp-pppoe/rp-pppoe.mk +0 -1
        for ff in $(RP_PPPOE_TARGET_FILES); do \
                $(INSTALL) -m 0755 $(@D)/src/$$ff $(TARGET_DIR)/usr/sbin/$$ff || exit 1; \
        done
--

2.2.0

_______________________________________________
buildroot mailing list
buildroot at busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

Signature · 8 lines
Matthew L Weber / Pr Software Engineer
Airborne Information Systems / Security Systems and Software
MS 131-100, C Ave NE, Cedar Rapids, IA, 52498, USA
www.rockwellcollins.com

Note: Any Export License Required Information and License Restricted
Third Party Intellectual Property (TPIP) content must be encrypted and
sent to matthew.weber at corp.rockwellcollins.com.