emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Correct / best way of loading packages in contrib when using org compiled from git?
@ 2013-02-21 11:56 Rainer M Krug
  2013-02-22 13:39 ` Bastien
  0 siblings, 1 reply; 10+ messages in thread
From: Rainer M Krug @ 2013-02-21 11:56 UTC (permalink / raw)
  To: emacs-orgmode

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi

I am using org-mode from git and compile it.

I would like to use the org-notmuch module in the contrib directory, and I activate it using:

 (add-to-list 'load-path "~/.emacs.d/org-mode/contrib/lisp")
 (require 'org-notmuch)

But, as Suvayo pointed out to me, in default.mk it says:

# Define if you want to include some (or all) files from contrib/lisp
# just the filename please (no path prefix, no .el suffix), maybe with globbing
#ORG_ADD_CONTRIB = org-e-* org-md org-export # e.g. the new exporter

So I would have to add

ORG_ADD_CONTRIB = org-notmuch

to the local.mk file

Nevertheless, I would like to stick with a configutration which uses the normal compiled version
and all configurations are in one file (emacs.org), so I would prefer the require... approach.

But I would like to have some clarification, what the differences are between the two approaches
and if (and if yes, why) it would be advisable to use the second approach.

Thanks  lot,

Rainer

PS: I update my git almost daily via the following script:

#############################3
#!/bin/sh
cd ~/.emacs.d/org-mode-git/org-mode

git checkout master
git fetch --tags origin

git pull
git gc

git checkout master

make clean
make
make autoloads
make doc
make info
#############################3



- -- 
Rainer M. Krug, PhD (Conservation Ecology, SUN), MSc (Conservation Biology, UCT), Dipl. Phys.
(Germany)

Centre of Excellence for Invasion Biology
Stellenbosch University
South Africa

Tel :       +33 - (0)9 53 10 27 44
Cell:       +33 - (0)6 85 62 59 98
Fax :       +33 - (0)9 58 10 27 44

Fax (D):    +49 - (0)3 21 21 25 22 44

email:      Rainer@krugs.de

Skype:      RMkrug
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRJgtRAAoJENvXNx4PUvmC6GgIANoMPX4TEwfjKVMstEoCHjFX
FYA1y2gRKFRRx0Qe/7gRMz7eMvHKrblnzH1A67MmUpGTO2H607pInMEsHsjWIcVH
EqfffwHdbSVMHaZwr6mKW+j0CXvGwVzviT2OrHl8BPMdt5DKScYuJBy7FUq2jKYg
9nZ7ATVs4ADy/Nxsqq7dcuJf2wDkw4ZWDgOnKu2guD5IFUVOgqe5H1vjEUa/veOH
V1VpuTjN7R5lWhVvxjDlLPzq4O3QGzmq5zj6S07wFJlx2dstN7mo6SP2RoiKO3Zl
Wc2KyK1+sMVpdZJDKtIyrJa1F4VTr40R0NtuC/ookq9j5b8H4R26LtDkxtUoncw=
=vRYR
-----END PGP SIGNATURE-----

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-21 11:56 Correct / best way of loading packages in contrib when using org compiled from git? Rainer M Krug
@ 2013-02-22 13:39 ` Bastien
  2013-02-22 14:08   ` Rainer M Krug
  0 siblings, 1 reply; 10+ messages in thread
From: Bastien @ 2013-02-22 13:39 UTC (permalink / raw)
  To: Rainer; +Cc: emacs-orgmode

Hi Rainer,

Rainer M Krug <r.m.krug@gmail.com> writes:

> #ORG_ADD_CONTRIB = org-e-* org-md org-export # e.g. the new exporter

The comment above was outdated since org-e-* files don't exist
anymore.  I updated it.

> So I would have to add
>
> ORG_ADD_CONTRIB = org-notmuch
>
> to the local.mk file

This is correct and will tell Org to compile and install
org-notmuch.el.

But you will still have to require it in your configuration.

> Nevertheless, I would like to stick with a configutration which uses the normal compiled version
> and all configurations are in one file (emacs.org), so I would prefer the require... approach.

Compiling, installing and requiring are three different things.

The makefile rules take care of the first two, while your config
file needs to take care of the third one in any case.

If you set the load-path to include the "contrib/lisp/" directory,
then you don't need to install org-notmuch, and (require 'org-notmuch)
will find it.

If you don't want to bother setting the load-path for "contrib/lisp/"
then you want to install Org.  In this case, org-notmuch will not be
installed unless you add the "ORG_ADD_CONTRIB = org-notmuch" rule.

> But I would like to have some clarification, what the differences are between the two approaches
> and if (and if yes, why) it would be advisable to use the second
> approach.

I hope the above clarifies things.

I don't install Org files, I use them from the git repo and configure
the require accordingly. 

> PS: I update my git almost daily via the following script:

This should be enough

#############################
#!/bin/sh
cd ~/.emacs.d/org-mode-git/org-mode
make update
#############################

HTH,

-- 
 Bastien

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-22 13:39 ` Bastien
@ 2013-02-22 14:08   ` Rainer M Krug
  2013-02-22 14:32     ` Bastien
  2013-02-22 21:17     ` Achim Gratz
  0 siblings, 2 replies; 10+ messages in thread
From: Rainer M Krug @ 2013-02-22 14:08 UTC (permalink / raw)
  To: Bastien, Rainer; +Cc: emacs-orgmode

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 22/02/13 14:39, Bastien wrote:
> Hi Rainer,
> 
> Rainer M Krug <r.m.krug@gmail.com> writes:
> 
>> #ORG_ADD_CONTRIB = org-e-* org-md org-export # e.g. the new exporter
> 
> The comment above was outdated since org-e-* files don't exist anymore.  I updated it.

Didn't realise that...

> 
>> So I would have to add
>> 
>> ORG_ADD_CONTRIB = org-notmuch
>> 
>> to the local.mk file
> 
> This is correct and will tell Org to compile and install org-notmuch.el.
> 
> But you will still have to require it in your configuration.

Ok - that makes sense. I just checked in my contrib/lisp and I only have .el there, so none are
compiled.

> 
>> Nevertheless, I would like to stick with a configutration which uses the normal compiled
>> version and all configurations are in one file (emacs.org), so I would prefer the require...
>> approach.
> 
> Compiling, installing and requiring are three different things.
> 
> The makefile rules take care of the first two, while your config file needs to take care of the
> third one in any case.

Ok.

> 
> If you set the load-path to include the "contrib/lisp/" directory, then you don't need to
> install org-notmuch, and (require 'org-notmuch) will find it.

Well - I don't install org, but just specify the load-path, so I have to specify that one as well.
No problem.

> 
> If you don't want to bother setting the load-path for "contrib/lisp/" then you want to install
> Org.  In this case, org-notmuch will not be installed unless you add the "ORG_ADD_CONTRIB =
> org-notmuch" rule.

Ok - makes sense.

> 
>> But I would like to have some clarification, what the differences are between the two
>> approaches and if (and if yes, why) it would be advisable to use the second approach.
> 
> I hope the above clarifies things.

Absolutely - thanks.

> 
> I don't install Org files, I use them from the git repo and configure the require accordingly.
> 
Yes - that is what I am doing as well.

Just for clarifications: is there any problem with adding

ORG_ADD_CONTRIB = *

to the local.mk file, apart from slightly longer compilation times?

> 
>> PS: I update my git almost daily via the following script:
> 
> This should be enough
> 
> ############################# #!/bin/sh cd ~/.emacs.d/org-mode-git/org-mode make update 
> #############################

Ok - I'll change it accordingly.

Thanks a lot,

Rainer

> 
> HTH,
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRJ3vRAAoJENvXNx4PUvmCabcH/AzwB4P8Qcu/mNBnx9rtwVgE
O2jVV7skAbrjExOI2lP1JLs2K1AAzbzYMapIMpNnzpU+2ozPvP390S6C9zs7EXMs
G0VRBDhOQxJyezXpeBkgdyxMxNwnPdkldvVeltMrJFEIRApe5Y2/NC7Zw6Lm+ASr
p/AxnIlZODZZTwZltvA/7wx6u1ZuWyH1jlEHbmpncqZqjqiimhLl5vXt3K8y3/GG
q7HDJwbDEVunWxWQZxvH7/E+QxnJV082tcKONDs8YJNaEo+7gnLiLnMUZS4sjBGi
NnkjoqCaWYltHTpZbG57YbzntFr4htn3k5KjxI4sKiMqLSgCW19ykTheOSC2dCA=
=TBD/
-----END PGP SIGNATURE-----

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-22 14:08   ` Rainer M Krug
@ 2013-02-22 14:32     ` Bastien
  2013-02-22 15:42       ` Achim Gratz
  2013-02-22 21:17     ` Achim Gratz
  1 sibling, 1 reply; 10+ messages in thread
From: Bastien @ 2013-02-22 14:32 UTC (permalink / raw)
  To: Rainer M Krug; +Cc: Rainer, emacs-orgmode

Rainer M Krug <r.m.krug@gmail.com> writes:

> Just for clarifications: is there any problem with adding
>
> ORG_ADD_CONTRIB = *
>
> to the local.mk file, apart from slightly longer compilation times?

This should be okay, but it's not safe.  If any non-emacs-lisp
file gets added to contrib/lisp/ (e.g. a README file) then you
will try to compile non-elisp files.  *\.el is safer.

-- 
 Bastien

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-22 14:32     ` Bastien
@ 2013-02-22 15:42       ` Achim Gratz
  2013-02-25 10:00         ` Rainer M Krug
  0 siblings, 1 reply; 10+ messages in thread
From: Achim Gratz @ 2013-02-22 15:42 UTC (permalink / raw)
  To: emacs-orgmode

Bastien <bzg <at> altern.org> writes:
> > Just for clarifications: is there any problem with adding
> >
> > ORG_ADD_CONTRIB = *
> >
> > to the local.mk file, apart from slightly longer compilation times?
> 
> This should be okay, but it's not safe.  If any non-emacs-lisp
> file gets added to contrib/lisp/ (e.g. a README file) then you
> will try to compile non-elisp files.  *\.el is safer.

This is a globbing pattern, not a regular expression, hence: "*.el", but that
would also pull in htmlize which you most likely don't want, so you might follow
the lead in server.mk and make that "org-*" or "org-*.el" if you are worried
that the Org maintainer forgets that only lisp files should go into the lisp
directory.  :-)


Regards,
Achim.

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-22 14:08   ` Rainer M Krug
  2013-02-22 14:32     ` Bastien
@ 2013-02-22 21:17     ` Achim Gratz
  2013-02-25 10:05       ` Rainer M Krug
  1 sibling, 1 reply; 10+ messages in thread
From: Achim Gratz @ 2013-02-22 21:17 UTC (permalink / raw)
  To: emacs-orgmode

Rainer M Krug writes:
> Ok - that makes sense. I just checked in my contrib/lisp and I only have .el there, so none are
> compiled.

Look in lisp, not contrib/lisp.

>> If you set the load-path to include the "contrib/lisp/" directory, then you don't need to
>> install org-notmuch, and (require 'org-notmuch) will find it.
>
> Well - I don't install org, but just specify the load-path, so I have to specify that one as well.
> No problem.

No, you don't want that if you use ORG_ADD_CONTRIB.

> Yes - that is what I am doing as well.

Just curious, what would change for you if you installed Org into a user
directory (besides using "make up2" instead of "make update")?

> Just for clarifications: is there any problem with adding
>
> ORG_ADD_CONTRIB = *
>
> to the local.mk file, apart from slightly longer compilation times?

Yes, you don't want all of contrib (htmlize.el in particular).

>>> PS: I update my git almost daily via the following script:
>> 
>> This should be enough

Actually, the "git checkout master" at the beginning should probably
stay there as a defensive measure.
 

Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

Wavetables for the Terratec KOMPLEXER:
http://Synth.Stromeko.net/Downloads.html#KomplexerWaves

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-22 15:42       ` Achim Gratz
@ 2013-02-25 10:00         ` Rainer M Krug
  2013-02-25 10:19           ` Bastien
  0 siblings, 1 reply; 10+ messages in thread
From: Rainer M Krug @ 2013-02-25 10:00 UTC (permalink / raw)
  To: Achim Gratz, emacs-orgmode, Bastien

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 22/02/13 16:42, Achim Gratz wrote:
> Bastien <bzg <at> altern.org> writes:
>>> Just for clarifications: is there any problem with adding
>>> 
>>> ORG_ADD_CONTRIB = *
>>> 
>>> to the local.mk file, apart from slightly longer compilation times?
>> 
>> This should be okay, but it's not safe.  If any non-emacs-lisp file gets added to
>> contrib/lisp/ (e.g. a README file) then you will try to compile non-elisp files.  *\.el is
>> safer.
> 
> This is a globbing pattern, not a regular expression, hence: "*.el", but that would also pull
> in htmlize which you most likely don't want, so you might follow the lead in server.mk and make
> that "org-*" or "org-*.el" if you are worried that the Org maintainer forgets that only lisp
> files should go into the lisp directory.  :-)

Thanks Bastien and Achim - I will then use "org-*.el"

Quick follow up question - what is the value for the Ubuntu package?

Rainer

> 
> 
> Regards, Achim.
> 
> 
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRKzZNAAoJENvXNx4PUvmC1EcH/AojCzTMu46oEjEClVLLfG0S
dju5QTA+1hfl8UfbTcY34aOwXP0CiGSxQtGF53M0CYxjFMI44o5yXVfHoKtKLwHQ
oII+6f6KT3kl2uhxJ6KUxZuvVZ5TRbse6Wse2NeacZRyHlioYYlf+nBVPBarZH+M
hPJIOYYPQUN4tEOdVRpjaWGGMzrXHxUqbY3KEWlVR6tYgPhsg4Pv7dzTr6ObW9qV
zrcBzHMoVTlgZXkNIcJu6wghwS2j/vLeFL3AHpxJyuM01nehY13KYsXxxl8ztDt3
YgGPsW3vbD0YdfEmhJLTPYxdskb13L5bFPMaFFObuoLdhI69PlmY3EEIXqUF0ZE=
=teLG
-----END PGP SIGNATURE-----

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-22 21:17     ` Achim Gratz
@ 2013-02-25 10:05       ` Rainer M Krug
  2013-02-25 17:37         ` Achim Gratz
  0 siblings, 1 reply; 10+ messages in thread
From: Rainer M Krug @ 2013-02-25 10:05 UTC (permalink / raw)
  To: Achim Gratz, emacs-orgmode

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 22/02/13 22:17, Achim Gratz wrote:
> Rainer M Krug writes:
>> Ok - that makes sense. I just checked in my contrib/lisp and I only have .el there, so none
>> are compiled.
> 
> Look in lisp, not contrib/lisp.

True - because it compiles it there.

> 
>>> If you set the load-path to include the "contrib/lisp/" directory, then you don't need to 
>>> install org-notmuch, and (require 'org-notmuch) will find it.
>> 
>> Well - I don't install org, but just specify the load-path, so I have to specify that one as
>> well. No problem.
> 
> No, you don't want that if you use ORG_ADD_CONTRIB.

Absolutely - if I use ORG_ADD_CONTRIB I don't want / need it, but If I don't, I do.

> 
>> Yes - that is what I am doing as well.
> 
> Just curious, what would change for you if you installed Org into a user directory (besides
> using "make up2" instead of "make update")?

Well - I could and I guess nothing would change. Why I like my setup at the moment is, that I have
all emacs config, installation and elpa in my .emacs.d directory. Would this be the same after
using "make up2"? Would I have to change paths somewhere?

> 
>> Just for clarifications: is there any problem with adding
>> 
>> ORG_ADD_CONTRIB = *
>> 
>> to the local.mk file, apart from slightly longer compilation times?
> 
> Yes, you don't want all of contrib (htmlize.el in particular).

Makes sense - changed it as described in the other email.

> 
>>>> PS: I update my git almost daily via the following script:
>>> 
>>> This should be enough
> 
> Actually, the "git checkout master" at the beginning should probably stay there as a defensive
> measure.

Ok - I just re-activate this command - shouldn't hurt.

Thanks a lot,

Rainer

> 
> 
> Regards, Achim.
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRKzddAAoJENvXNx4PUvmCl+QIAK7kGmIbrO1j/cgOjEJXd/Xr
6snTTUf4epB0ZAuOVEXoC38GA7bdVcxJa8kJlE/LC6SCgTncljS57T8PXXmlF29F
66QY5GMsMhS0ySR4NERrloo3TWlomcfD6jSc/EzBJHP4ErDQ4J52EL0RwcO71/F6
sTK96TM06UlSta389/cKn/PMtIwVqi/oav2z1zFINVNFjYCxEOVkj0+ei03k/bmO
8aywm19q0UOPPL2mjnCI8cxEzfpzX2/WZllplXvSYYUIf5bz+JmMMZfQsawmmzWA
9YX31Usb7i3TM/7OhlOX/sahjdlJ2JvV7uqxg2Dj2KnzrlXCXq1+jyNKU0GlFbQ=
=4J3Q
-----END PGP SIGNATURE-----

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-25 10:00         ` Rainer M Krug
@ 2013-02-25 10:19           ` Bastien
  0 siblings, 0 replies; 10+ messages in thread
From: Bastien @ 2013-02-25 10:19 UTC (permalink / raw)
  To: Rainer M Krug; +Cc: Achim Gratz, emacs-orgmode

Rainer M Krug <r.m.krug@gmail.com> writes:

> Quick follow up question - what is the value for the Ubuntu package?

I'm not using Ubuntu so I don't know, sorry!

-- 
 Bastien

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

* Re: Correct / best way of loading packages in contrib when using org compiled from git?
  2013-02-25 10:05       ` Rainer M Krug
@ 2013-02-25 17:37         ` Achim Gratz
  0 siblings, 0 replies; 10+ messages in thread
From: Achim Gratz @ 2013-02-25 17:37 UTC (permalink / raw)
  To: emacs-orgmode

Rainer M Krug writes:
> Well - I could and I guess nothing would change. Why I like my setup at the moment is, that I have
> all emacs config, installation and elpa in my .emacs.d directory. Would this be the same after
> using "make up2"? Would I have to change paths somewhere?

You can install Org wherever you like if you let your Emacs
configuration find it.  You need to put suitable definitions for lispdir
datadir and infodir into local.mk, the easiest way is probably to just
point prefix at your emacs.d (you must use the absolute path, not the
tilde abbreviation ~/...).  Check the result of these changes with "make
config" before you first install.


Regards,
Achim.
-- 
+<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+

SD adaptation for Waldorf rackAttack V1.04R1:
http://Synth.Stromeko.net/Downloads.html#WaldorfSDada

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

end of thread, other threads:[~2013-02-25 17:38 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-21 11:56 Correct / best way of loading packages in contrib when using org compiled from git? Rainer M Krug
2013-02-22 13:39 ` Bastien
2013-02-22 14:08   ` Rainer M Krug
2013-02-22 14:32     ` Bastien
2013-02-22 15:42       ` Achim Gratz
2013-02-25 10:00         ` Rainer M Krug
2013-02-25 10:19           ` Bastien
2013-02-22 21:17     ` Achim Gratz
2013-02-25 10:05       ` Rainer M Krug
2013-02-25 17:37         ` Achim Gratz

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).