Skip to content

Instantly share code, notes, and snippets.

@npf
Created May 6, 2015 15:14
Show Gist options
  • Save npf/7c46d7ce161bf2943bed to your computer and use it in GitHub Desktop.
Save npf/7c46d7ce161bf2943bed to your computer and use it in GitHub Desktop.
$(TEMPLATE_BUILDED_FILES) : $(patsubst %, %.in,$*)
perl -pe "s#%%PREFIX%%#$(PREFIX)#g;;\
s#%%BINDIR%%#$(BINDIR)#g;;\
s#%%CGIDIR%%#$(CGIDIR)#g;;\
s#%%DOCDIR%%#$(DOCDIR)#g;;\
s#%%EXAMPLEDIR%%#$(EXAMPLEDIR)#g;;\
s#%%ETCDIR%%#$(ETCDIR)#g;;\
s#%%OARCONFDIR%%#$(OARCONFDIR)#g;;\
s#%%OARDIR%%#$(OARDIR)#g;;\
s#%%SHAREDIR%%#$(SHAREDIR)#g;;\
s#%%PERLLIBDIR%%#$(PERLLIBDIR)#g;;\
s#%%RUNDIR%%#$(RUNDIR)#g;;\
s#%%LOGDIR%%#$(LOGDIR)#g;;\
s#%%MANDIR%%#$(MANDIR)#g;;\
s#%%SBINDIR%%#$(SBINDIR)#g;;\
s#%%VARLIBDIR%%#$(VARLIBDIR)#g;;\
s#%%OARHOMEDIR%%#$(OARHOMEDIR)#g;;\
s#%%ROOTUSER%%#$(ROOTUSER)#g;;\
s#%%ROOTGROUP%%#$(ROOTGROUP)#g;;\
s#%%OARDO_DEFAULTUSER%%#$(OARDO_DEFAULTUSER)#g;;\
s#%%OARDO_DEFAULTGROUP%%#$(OARDO_DEFAULTGROUP)#g;;\
s#%%OARUSER%%#$(OARUSER)#g;;\
s#%%OAROWNER%%#$(OAROWNER)#g;;\
s#%%OAROWNERGROUP%%#$(OAROWNERGROUP)#g;;\
s#%%WWWUSER%%#$(WWWUSER)#g;;\
s#%%APACHECONFDIR%%#$(APACHECONFDIR)#g;;\
s#%%WWW_ROOTDIR%%#$(WWW_ROOTDIR)#g;;\
s#%%WWWDIR%%#$(WWWDIR)#g;;\
s#%%XAUTHCMDPATH%%#$(XAUTHCMDPATH)#g;;\
s#%%OARSHCMD%%#$(OARSHCMD)#g;;\
s#%%INITDIR%%#$(INITDIR)#g;;\
s#%%DEFAULTDIR%%#$(DEFAULTDIR)#g;;\
s#%%SETUP_TYPE%%#$(SETUP_TYPE)#g;;\
s#%%TARGET_DIST%%#$(TARGET_DIST)#g;;\
" "[email protected]" > $@
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment