mailarchive of the ptxdist mailing list
 help / color / mirror / Atom feed
* [ptxdist] install_replace on a {pre,post}{rm,inst} script
@ 2011-11-10 10:45 Benoît BURNICHON
  2011-11-10 12:34 ` Benoît BURNICHON
  2011-11-20 12:44 ` [ptxdist] [PATCH] add install_script_replace to replace in pre/post scripts Michael Olbrich
  0 siblings, 2 replies; 3+ messages in thread
From: Benoît BURNICHON @ 2011-11-10 10:45 UTC (permalink / raw)
  To: ptxdist

Hi all,

I would like to perform an action like is done on lighttpd package.
        @$(call install_replace, lighttpd, /etc/lighttpd/lighttpd.conf, \
                @CGI@, $(call ptx/ifdef, PTXCONF_PHP5_SAPI_CGI,,#))

Problem is, that I want to perform the same thing in the install scripts:
        @$(call install_script_replace, mypackage, postinst, \
                @INSTALLDIR@,$(MYPACKAGE_LOCATION))

This way, I can choose the destination directory from the ptxdist menu.

BTW, the script postinst are run by ptxdist at targetinstall stage. The scripts should not fail on this call.

When using ipkg or opkg, scripts are called with different parameters:
        - Ptxdist calls without arguments and with DESTDIR environment variable set to destination (nfs root or root-debug dir)
        - Ipkg calls postinstall scripts with 'configure' argument and PKG_ROOT environment variable set to the destination.
        - Ipkg can be called with -o (--offline) argument to set the offline directory to install to. (But be careful, there is no environment variables indicating that the install is an offline one)

Regards,

Ben

________________________________

Ce courriel et toutes les pièces jointes sont confidentiels et peuvent être couverts par un privilège ou une protection légale. Il est établi à l’attention exclusive de ses destinataires. Toute utilisation de ce courriel non conforme à sa destination, toute diffusion ou toute publication, totale ou partielle, est interdite, sauf autorisation expresse préalable.
This email and any attachment are confidential and may be legally privileged or otherwise protected from disclosure. It is intended only for the stated addressee(s) and access to it by any other person(s) is unauthorized. Any use, dissemination or disclosure not in accordance with its purpose, either in whole or in part, is prohibited without our prior formal approval.
-- 
ptxdist mailing list
ptxdist@pengutronix.de

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-11-20 12:44 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-11-10 10:45 [ptxdist] install_replace on a {pre,post}{rm,inst} script Benoît BURNICHON
2011-11-10 12:34 ` Benoît BURNICHON
2011-11-20 12:44 ` [ptxdist] [PATCH] add install_script_replace to replace in pre/post scripts Michael Olbrich

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox