all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Guix packaging, dealing with pkg-config
@ 2019-07-24  9:15 Ekaitz at ElenQ Technology
  2019-07-24 13:31 ` Ricardo Wurmus
  0 siblings, 1 reply; 7+ messages in thread
From: Ekaitz at ElenQ Technology @ 2019-07-24  9:15 UTC (permalink / raw)
  To: help-guix@gnu.org

Hi everyone,

I'm starting to learn how to make my own packages with Guix and I encountered a problem when trying to make a (pretty simple) package definition for sc-im.

This is the package definition I made:

https://gitlab.com/ekaitz-zarraga/guix-packages/blob/master/sc-im.scm

The problem I see is the project is doing a heavy use of the Makefile with pkg-config and it's searching for lua5.1. I am unable to install Lua and find it with pkg-config and I'm pretty sure the compilation that Guix does is not finding it.

What should I do to solve this problem?
Ideas?

The only idea I can think of is to make a patch on the makefile and remove pkg-config related stuff, but I'm pretty sure there's a more elegant solution.

Thank you,
Ekaitz


ElenQ Technology
Ethical Innovation

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

* Re: Guix packaging, dealing with pkg-config
  2019-07-24  9:15 Guix packaging, dealing with pkg-config Ekaitz at ElenQ Technology
@ 2019-07-24 13:31 ` Ricardo Wurmus
  2019-07-24 13:38   ` Ekaitz at ElenQ Technology
  0 siblings, 1 reply; 7+ messages in thread
From: Ricardo Wurmus @ 2019-07-24 13:31 UTC (permalink / raw)
  To: Ekaitz at ElenQ Technology; +Cc: help-guix@gnu.org


Ekaitz at ElenQ Technology <ekaitz@elenq.tech> writes:

> The problem I see is the project is doing a heavy use of the Makefile
> with pkg-config and it's searching for lua5.1.

This should not be problematic.

> I am unable to install Lua and find it with pkg-config and I'm pretty
> sure the compilation that Guix does is not finding it.

Oh?  I just checked and our lua5.1 package does provide a
/lib/pkgconfig/lua-5.1.pc file, so finding it with pkg-config should
work.

> The only idea I can think of is to make a patch on the makefile and
> remove pkg-config related stuff, but I'm pretty sure there's a more
> elegant solution.

I’m pretty sure that this can be avoided.

--
Ricardo

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

* Re: Guix packaging, dealing with pkg-config
  2019-07-24 13:31 ` Ricardo Wurmus
@ 2019-07-24 13:38   ` Ekaitz at ElenQ Technology
  2019-07-24 18:07     ` Ricardo Wurmus
  0 siblings, 1 reply; 7+ messages in thread
From: Ekaitz at ElenQ Technology @ 2019-07-24 13:38 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: help-guix\@gnu.org

Great,

I must be missing something then because I'm sure it's not finding it :(

Might be my library path or something related?

Any clue?


ElenQ Technology
Ethical Innovation

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Wednesday, July 24, 2019 3:31 PM, Ricardo Wurmus <rekado@elephly.net> wrote:

>
>
> Ekaitz at ElenQ Technologyekaitz@elenq.tech writes:
>
> > The problem I see is the project is doing a heavy use of the Makefile
> > with pkg-config and it's searching for lua5.1.
>
> This should not be problematic.
>
> > I am unable to install Lua and find it with pkg-config and I'm pretty
> > sure the compilation that Guix does is not finding it.
>
> Oh? I just checked and our lua5.1 package does provide a
> /lib/pkgconfig/lua-5.1.pc file, so finding it with pkg-config should
> work.
>
> > The only idea I can think of is to make a patch on the makefile and
> > remove pkg-config related stuff, but I'm pretty sure there's a more
> > elegant solution.
>
> I’m pretty sure that this can be avoided.
>
> --------------------------------------------
>
> Ricardo

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

* Re: Guix packaging, dealing with pkg-config
  2019-07-24 13:38   ` Ekaitz at ElenQ Technology
@ 2019-07-24 18:07     ` Ricardo Wurmus
  2019-07-25  1:49       ` Ekaitz at ElenQ Technology
  0 siblings, 1 reply; 7+ messages in thread
From: Ricardo Wurmus @ 2019-07-24 18:07 UTC (permalink / raw)
  To: Ekaitz at ElenQ Technology; +Cc: help-guix@gnu.org


Ekaitz at ElenQ Technology <ekaitz@elenq.tech> writes:

> I must be missing something then because I'm sure it's not finding it :(

Can you show us the pkg-config command you’re using?

-- 
Ricardo

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

* Re: Guix packaging, dealing with pkg-config
  2019-07-24 18:07     ` Ricardo Wurmus
@ 2019-07-25  1:49       ` Ekaitz at ElenQ Technology
  2019-07-25  7:01         ` Ricardo Wurmus
  0 siblings, 1 reply; 7+ messages in thread
From: Ekaitz at ElenQ Technology @ 2019-07-25  1:49 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: help-guix\@gnu.org


On Wednesday, July 24, 2019 8:07 PM, Ricardo Wurmus <rekado@elephly.net> wrote:

> Ekaitz at ElenQ Technologyekaitz@elenq.tech writes:
>
> > I must be missing something then because I'm sure it's not finding it :(
>
> Can you show us the pkg-config command you’re using?
>
> -------------------------------------------------------

Yeah, there are in the original makefiles of sc-im:
https://github.com/andmarti1424/sc-im/blob/freeze/src/Makefile#L124

I'm not used to pkg-config neither so I'm not really sure of what I should do with it.

Thanks!

Ekaitz

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

* Re: Guix packaging, dealing with pkg-config
  2019-07-25  1:49       ` Ekaitz at ElenQ Technology
@ 2019-07-25  7:01         ` Ricardo Wurmus
  2019-07-25 11:19           ` Ekaitz at ElenQ Technology
  0 siblings, 1 reply; 7+ messages in thread
From: Ricardo Wurmus @ 2019-07-25  7:01 UTC (permalink / raw)
  To: Ekaitz at ElenQ Technology; +Cc: help-guix@gnu.org


Ekaitz at ElenQ Technology <ekaitz@elenq.tech> writes:

> Yeah, there are in the original makefiles of sc-im:
> https://github.com/andmarti1424/sc-im/blob/freeze/src/Makefile#L124

The FreeBSD case (line 128 and following) works for me:

    $ guix environment --ad-hoc lua@5.1 pkg-config
    [env] $ pkg-config --exists lua51 && echo yes || echo no
    no
    [env] $ pkg-config --exists lua-5.1 && echo yes || echo no
    yes
    [env] $ pkg-config --cflags lua-5.1
    -I/gnu/store/yl6v5ma16ya9b6npwqlrcp9pr2gqp6dc-lua-5.1.5/include
    [env] $ pkg-config --libs lua-5.1
    -L/gnu/store/yl6v5ma16ya9b6npwqlrcp9pr2gqp6dc-lua-5.1.5/lib -llua -lm

So this works just fine.

--
Ricardo

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

* Re: Guix packaging, dealing with pkg-config
  2019-07-25  7:01         ` Ricardo Wurmus
@ 2019-07-25 11:19           ` Ekaitz at ElenQ Technology
  0 siblings, 0 replies; 7+ messages in thread
From: Ekaitz at ElenQ Technology @ 2019-07-25 11:19 UTC (permalink / raw)
  To: Ricardo Wurmus; +Cc: help-guix\@gnu.org

On Thursday, July 25, 2019 9:01 AM, Ricardo Wurmus <rekado@elephly.net> wrote:

>
>
> Ekaitz at ElenQ Technologyekaitz@elenq.tech writes:
>
> > Yeah, there are in the original makefiles of sc-im:
> > https://github.com/andmarti1424/sc-im/blob/freeze/src/Makefile#L124
>
> The FreeBSD case (line 128 and following) works for me:
>
> $ guix environment --ad-hoc lua@5.1 pkg-config
> [env] $ pkg-config --exists lua51 && echo yes || echo no
> no
> [env] $ pkg-config --exists lua-5.1 && echo yes || echo no
> yes
> [env] $ pkg-config --cflags lua-5.1
> -I/gnu/store/yl6v5ma16ya9b6npwqlrcp9pr2gqp6dc-lua-5.1.5/include
> [env] $ pkg-config --libs lua-5.1
> -L/gnu/store/yl6v5ma16ya9b6npwqlrcp9pr2gqp6dc-lua-5.1.5/lib -llua -lm
>
> So this works just fine.
>

Yes, the guix environment works fine for me too!


But, when I run --version in the recently built one I don't get any reference to lua support.


$ /gnu/store/svn5hkyckw9gmcdhybs5599mcbrkydyx-sc-im-freeze/bin/sc-im  --version
Sc-im - version 0.7.0
-DNCURSES
-DMAXROWS 1048576
-DUNDO
-DDEFAULT_COPY_TO_CLIPBOARD_CMD="xclip -i -selection clipboard <"
-DDEFAULT_PASTE_FROM_CLIPBOARD_CMD="xclip -o -selection clipboard"
-DUSELOCALE
-DUSECOLORS
-D_XOPEN_SOURCE_EXTENDED
-D_GNU_SOURCE
-DSNAME="sc-im"
-DHELP_PATH="/gnu/store/svn5hkyckw9gmcdhybs5599mcbrkydyx-sc-im-freeze/share/sc-im"
-DLIBDIR="/gnu/store/svn5hkyckw9gmcdhybs5599mcbrkydyx-sc-im-freeze/share/doc/sc-im"
-DDFLT_PAGER="less"
-DHISTORY_FILE=".sc-iminfo"
-DINS_HISTORY_FILE=".sc-iminfo"
-DHAVE_PTHREAD
-DAUTOBACKUP

When the package is building and all the commands executed by the makefile are printed, there's no reference to any Lua flag that should be there like -DXLUA or all of those flags added by the makefile. So, it's working but the makefile is somehow ignoring the package or I added it incorrectly in the definition.

Thoughts?

Thanks you,
Ekaitz

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

end of thread, other threads:[~2019-07-25 11:19 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-07-24  9:15 Guix packaging, dealing with pkg-config Ekaitz at ElenQ Technology
2019-07-24 13:31 ` Ricardo Wurmus
2019-07-24 13:38   ` Ekaitz at ElenQ Technology
2019-07-24 18:07     ` Ricardo Wurmus
2019-07-25  1:49       ` Ekaitz at ElenQ Technology
2019-07-25  7:01         ` Ricardo Wurmus
2019-07-25 11:19           ` Ekaitz at ElenQ Technology

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.