How to write to /etc and other files in a Makefile
hello there all I am trying to package up a well package and am having troubles with the Makefile. I need to mkdir to etc and I keep on getting permissions troubles. What is the work around for this. example of my make file
Code:
#!/usr/bin/make
install:
mkdir -p /etc/zpanel
mkdir -p /etc/zpanel/configs
mv $(CURDIR)/ubuntu_11_10/ /etc/zpanel/configs
mkdir -p /etc/zpanel/panel
mkdir -p /etc/zpanel/docs
mkdir -p /var/zpanel
mkdir -p /var/zpanel/hostdata
mkdir -p /var/zpanel/hostdata/zadmin
mkdir -p /var/zpanel/hostdata/zadmin/public_html
mkdir -p /var/zpanel/logs
mkdir -p /var/zpanel/backups
mkdir -p /var/zpanel/temp
install -m 755 $(CURDIR)/setso /usr/bin
install -m 755 $(CURDIR)/zppy /usr/bin
I am real new to making a makefile.
also how to cp -r something in a make file
Code:
#!/usr/bin/make
install:
cp $(CURDIR)/ubuntu_11_10/* /etc/zpanel/configs
??
Thanks for your time.
This is my plan
make the make file that makes the new dirs and prep for dh_make
run dh_make alter the debian folder
build package
Last edited by josephmills; April 18th, 2012 at 02:10 AM.
Power tends to corrupt, and absolute power corrupts absolutely. Great men are almost always bad men, even when they exercise influence and not authority
Bookmarks