Re: [yocto] Meta layer for pine64

2016-09-23 Thread Mont3z Claros
Hi all,

On Thu, Sep 22, 2016 at 12:55 PM, Mont3z Claros  wrote:
> On Thu, Sep 22, 2016 at 10:21 AM, Khem Raj  wrote:
>> On Thu, Sep 22, 2016 at 8:29 AM, Tom Rini  wrote:
>>> On Wed, Sep 21, 2016 at 11:39:48AM -0700, Khem Raj wrote:
 On Fri, Sep 16, 2016 at 2:01 PM, Mont3z Claros  
 wrote:
 > Hi all,
 >
 > I just finished a first beta version of a meta layer for SBC pine64.
 > You can find it in  https://github.com/mont3z/meta-pine64
 >
 > I'd appreciate if anyone has any comments on possible improvements. A
 > major problem I had was the necessity of two toolchains: one for
 > compiling u-boot (32 bits) and another for compiling all other
 > components (64 bis). At the moment I have a very ugly hack to do it.
 > The 32 bit toolchain is an external toolchain and I set PATH
 > environmental variable in u-boot recipe.

 I think it would be desirable to have single toolchain, u-boot is a
 stand alone app
 in general, if your compiler can do multilib builds for 32bit then it
 would be possible
 to build it. May be you should work with the toolchain team for pine64 to 
 see if
 that can be done. It will simplify using this layer.
>>>
>>> Actually, pine64 has a 64bit U-Boot, I think maybe the layer just needs
>>> to be updated to use mainline (or v2016.09.01) U-Boot.
>>>
 Other option I would suggest to build u-boot externally for your SoC, we do
 not necessarily need a bootloader for building final images anyway.
>>>
>>> Well, you do if you want a bootable image to be made :)  iirc all of the
>>> models are SD card only, no eMMC so assuming firmware "elsewhere" is a
>>> bad idea.
>>
>> You can always write a recipe to package a prebuilt u-boot.
>>
>
> Hi all,
>
> unfortunately the pine64 mainlilne u-boot is not compatible with the
> kernel I'm compiling.
> To package a prebuilt u-boot could be one solution. At the moment I'm
> investigating the possibility
> of patching u-boot to compile it with multilib.
>

from my research unfortunately the Cortex A53 from pine64 boots in
32-bit mode with armv7-a instruction set.
This means I cannot use -mabi=ilp32 from aarch64 toolchain to compile it.

After some discussion I also found that if I try to use pine64
mainline u-boot than I would need add support to every
weird interface that AW came up with. Which is something I don't even
understand. :-)

So, I'm considering to leave as it is for now and I'll try to add
recipes for mainline u-boot and mainline kernel (which is still beta).

Thanks,
Montez
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


Re: [yocto] How to add my own c++ project into a Yocto distro

2016-09-23 Thread Daniel.
I'm building libraries at my work with plain makefiles and getting the
code from SVN. There is no secret just follow the docs... One thing to
know is about compiling using run_oemake instead of simple "make" at
do_compile and that you may want to use CFLAGS_prefix = "some flags".
Dependencies should be added to DEPENDS_${PN} and running dependencies
to RDEPEND. Also you should remeber that Yocto will try to run
parallel builds so is a nice testing running make -j4 or make -j8 or
whatever you want, just to make sure that your Makefile is supporting
parallel building fine. If you want to inhibit parallel build at all
you can use .NOPARALLEL pseudo target, but this may make things
slower. I hope this helps,

Best regards and good lucky!

2016-09-23 17:10 GMT-03:00 Fred Ollinger :
> Here's how to write a recipe:
>
>
> http://www.yoctoproject.org/docs/1.6/dev-manual/dev-manual.html#new-recipe-writing-a-new-recipe
>
>
> When we started, we also had custom Makefiles. However, we found it was 
> easier to add our recipes to automake before making a bitbake recipe.
>
> Automake is a challenge to get started, but worth learning.
>
> I don't regret our move to it.
>
> There are other options that work equally in yocto, though, like cmake.
>
>
> https://www.gnu.org/software/automake/manual/html_node/Hello-World.html
>
> 
> From: yocto-boun...@yoctoproject.org  on 
> behalf of Karim ATIKI 
> Sent: Friday, September 23, 2016 12:53 PM
> To: yocto@yoctoproject.org
> Subject: [yocto] How to add my own c++ project into a Yocto distro
>
>
> Hi all,
>
>
> I have setup a Poky distribution based on a core-image-sato image for both 
> RaspberryPi and Toradex Colibri T20.
>
> I have an X11 environment working fine.
>
>
> Right now, I need to compile our software we developped.
>
> I basically need to fetch SVN repositories and finally to launch a makefile 
> to get everyting work.
>
> The makefile is however not based on autotools. It's a custom makefiles with 
> regular dependencies.
>
>
> I just don't know how to achieve this step in Yocto ?
>
> Should I add a recipe ?
>
> Is there a link that describes what I need to achieve ?
>
>
> Thanks
>
>
> Karim
> --
> ___
> yocto mailing list
> yocto@yoctoproject.org
> https://lists.yoctoproject.org/listinfo/yocto



-- 
"Do or do not. There is no try"
  Yoda Master
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


Re: [yocto] How to add my own c++ project into a Yocto distro

2016-09-23 Thread Fred Ollinger
Here's how to write a recipe:


http://www.yoctoproject.org/docs/1.6/dev-manual/dev-manual.html#new-recipe-writing-a-new-recipe


When we started, we also had custom Makefiles. However, we found it was easier 
to add our recipes to automake before making a bitbake recipe.

Automake is a challenge to get started, but worth learning.

I don't regret our move to it.

There are other options that work equally in yocto, though, like cmake.


https://www.gnu.org/software/automake/manual/html_node/Hello-World.html


From: yocto-boun...@yoctoproject.org  on behalf 
of Karim ATIKI 
Sent: Friday, September 23, 2016 12:53 PM
To: yocto@yoctoproject.org
Subject: [yocto] How to add my own c++ project into a Yocto distro


Hi all,


I have setup a Poky distribution based on a core-image-sato image for both 
RaspberryPi and Toradex Colibri T20.

I have an X11 environment working fine.


Right now, I need to compile our software we developped.

I basically need to fetch SVN repositories and finally to launch a makefile to 
get everyting work.

The makefile is however not based on autotools. It's a custom makefiles with 
regular dependencies.


I just don't know how to achieve this step in Yocto ?

Should I add a recipe ?

Is there a link that describes what I need to achieve ?


Thanks


Karim
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


[yocto] How to add my own c++ project into a Yocto distro

2016-09-23 Thread Karim ATIKI
Hi all,


I have setup a Poky distribution based on a core-image-sato image for both 
RaspberryPi and Toradex Colibri T20.

I have an X11 environment working fine.


Right now, I need to compile our software we developped.

I basically need to fetch SVN repositories and finally to launch a makefile to 
get everyting work.

The makefile is however not based on autotools. It's a custom makefiles with 
regular dependencies.


I just don't know how to achieve this step in Yocto ?

Should I add a recipe ?

Is there a link that describes what I need to achieve ?


Thanks


Karim
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


Re: [yocto] Freescale DPAA drivers

2016-09-23 Thread Lennart Sorensen
On Fri, Sep 23, 2016 at 02:13:43PM +, Anicic Damir (PSI) wrote:
> I am using Yocto 2.1, PowerPC64, default kernel 4.1.22
> Building for T2080rdb.
> 
> Everything builds, but kernel is missing DPAA Freescale drivers
> (dpaa_eth at least)
> 
> 
> It seems that DPAA Freescale drivers not in any Linux kernel (or am I wrong).
> 
> Why is that so, is Freescale not planing to include them in kernel ?

I have seen them try.  There was a v5 patch for dpaa_eth in December 2015,
but I don't know what happened after that.

There is drivers/staging/fsl-mc/ in the most recent kernel, but I am
not sure that's everything needed yet.

In fact today there was:

http://lkml.iu.edu/hypermail/linux/kernel/1609.2/04508.html
http://lkml.iu.edu/hypermail/linux/kernel/1609.2/00356.html

So they are trying again it seems.

-- 
Len Sorensen
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


Re: [yocto] build ntp with openssl support

2016-09-23 Thread Lennart Sorensen
On Fri, Sep 23, 2016 at 02:19:20PM +0200, Oliver Graute wrote:
> On 22/09/16, Khem Raj wrote:
> > On Thu, Sep 22, 2016 at 12:16 AM, Oliver Graute  
> > wrote:
> > > On 19/09/16, Oliver Graute wrote:
> > >> On 16/09/16, Andre McCurdy wrote:
> > >> > On Fri, Sep 16, 2016 at 1:24 AM, Oliver Graute 
> > >> >  wrote:
> > >> > > Hello,
> > >> > >
> > >> > > how can I build ntp with openssl support?
> > >> > >
> > >> > > I already created a ntp_%.bbappend file to extend the recipe 
> > >> > > ntp_4.2.8p4.bb.
> > >> > >
> > >> > > FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
> > >> >
> > >> > You don't really need this line unless you are adding a file to
> > >> > SRC_URI or replacing a file already in SRC_URI with your own version.
> > >> >
> > >> > > PACKAGECONFIG += "openssl"
> > >> >
> > >> > This will enable openssl, but it will also disable all the default
> > >> > PACKAGECONFIG options (cap, debug and refclocks) which is probably not
> > >> > what you want. Try this instead:
> > >> >
> > >> >   PACKAGECONFIG_append = " openssl"
> > >> >
> > >> > Note the space between " and openssl. It's required.
> > >>
> > >> ok now I see the right configure script options during the configuration
> > >> of the ntp build.
> > >>
> > >> --with-openssl-libdir=/home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/lib
> > >> --with-openssl-incdir=/home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/include
> > >> --with-crypto
> > >>
> > >> But ntp is still build without openssl support. The configure scripts
> > >> can't find the relevant openssl stuff.
> > >>
> > >> configure:34762: checking for openssl library directory
> > >> configure:34802: result: no
> > >> configure:34807: WARNING: libcrypto and libssl not found in any of 
> > >> /home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/lib
> > >> configure:34811: checking for openssl include directory
> > >> configure:34833: result: 
> > >> /home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/include
> > >> configure:34877: checking if we will use crypto
> > >> configure:34879: result: no
> > >> configure:35109: checking if we want to use OpenSSL's crypto random (if 
> > >> available)
> > >> configure:35119: result: yes
> > >>
> > >> some clue whats wrong here?
> > >
> > > in my sysroots/imx6ulevk/usr/lib I have
> > >
> > > ls -la libssl*
> > >
> > > libssl3.so
> > > libssl.a
> > > libssl.so -> libssl.so.1.0.0
> > > libssl.so.1.0.0
> > >
> > > ls -la libcrypt*
> > >
> > > libcrypt.a
> > > libcrypt_pic.a
> > > libcrypt_pic.map
> > > libcrypt.so -> ../../lib/libcrypt.so.1
> > >
> > >
> > > but no libcrypto.so. I guess thats the reason why my ntp configure
> > > script is complaining.
> > >
> > > Some ideas how to get libcrypto.so in my /usr/lib folder in the yocto
> > > sysroot?
> > >
> > 
> > It seems your openssl is not being compiled correctly. Can you go into
> > builddir or openssl
> > and see if libcrypto.so.1.0.0 is built ? if not then you have to do
> > some digging why its not
> > configuring to build libcrypto
> 
> libcrypto is build by openssl
> 
> openssl/1.0.2d-r0/openssl-1.0.2d$ ls -la  libcrypt*
> libcrypto.a
> libcrypto.pc
> libcrypto.so -> libcrypto.so.1.0.0
> libcrypto.so.1.0.0
> 
> but in my sysroot libcrypto is located in lib NOT in usr/lib
> 
> the ntp recipe in 
> meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p4.bb
> defines:
> 
>  --with-openssl-libdir=${STAGING_LIBDIR}
> 
> I assume I need ${STAGING_BASELIBDIR} here instead. But currently I fail
> with overwriting this in my bbappend file.
> 
> If I use EXTRA_OECONF to overwrite it in my bbappend I see two 
> --with-openssl-libdir
> statements while configuring. The first with /lib the second one with 
> /usr/lib. 
> 
> EXTRA_OECONF  += "\
>   --with-openssl \
>   --with-openssl-libdir=${STAGING_BASELIBDIR} \
>   --with-openssl-incdir=${STAGING_INCDIR} \
>   --with-crypto \
> "

I have a .bbappend file containing:

# This is wrong in the upstream .bb file and doesn't work so override it
PACKAGECONFIG[openssl] = "--with-crypto, \
  --without-crypto, \
  openssl"
PACKAGECONFIG_append = " openssl"

By NOT specifying the directories, it uses pkg-config, which of course
returns both directories correctly.  The ntp configure script can't
imagine that the openssl libraries are in two different directories at
the same time and hence fails to find them even though it searches both
of them, but only trying one at a time.

-- 
Len Sorensen
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


[yocto] Yocto Project Status WW39

2016-09-23 Thread Jolley, Stephen K
Current Dev Position: YP 2.2 M4

Next Deadline: YP 2.2 M4 which will be Oct. 3rd (5:00pm GMT)


SWAT team rotation: Maxin -> Joshua

https://wiki.yoctoproject.org/wiki/Yocto_Build_Failure_Swat_Team


Key Status/Updates:

*The M3rc1 QA report is out and likely to be released. There were a 
number of bugs, particularly in and around the recent runqemu changes but we 
plan to address these and pretest them before the first M4 rc build.

*We're making good progress with bug fixing and there are some good 
fixes and tweaks going into master. There are also some problems we're seeing 
with build artefacts, particularly with buildtools and uninative which are 
preventing a new uninative release (after the patchelf upgrade).

*Our final release is also dependent on the 4.8 kernel release.

*We have merged various krogoth patches (thanks Armin!). The test 
builds still did show some issues, particularly as the autobuilder has 
increased test coverage but I think we've worked through several of them.

*The defect tracking metric did rise slightly this week from bugs from 
the M3 QA process.


Key YP 2.2 Dates:

*YP 2.2 M4 cut off would be: 10/3/16

*YP 2.2 M4 release would be: 10/28/16


Tracking Metrics:

WDD 2557 (last week 2531)

(https://wiki.yoctoproject.org/charts/combo.html)


Key Status Links for YP:

https://wiki.yoctoproject.org/wiki/Yocto_Project_v2.2_Status

https://wiki.yoctoproject.org/wiki/Yocto_2.2_Schedule

https://wiki.yoctoproject.org/wiki/Yocto_2.2_Features

[If anyone has suggestions for other information you'd like to see on this 
weekly status update, let us know!]

Thanks,

Stephen K. Jolley
Yocto Project Program Manager
INTEL, MS JF1-255, 2111 N.E. 25th Avenue, Hillsboro, OR 97124
*   Work Telephone:(503) 712-0534
*Cell:   (208) 244-4460
* Email:stephen.k.jol...@intel.com

-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


Re: [yocto] Freescale DPAA drivers

2016-09-23 Thread Zhenhua Luo
I guess you are using the community kernel instead of NXP SDK kernel, the DPAA 
upstream is ongoing currently, to use the full function DPAA drivers, you can 
use the kernel recipes in meta-fsl-ppc 
layer(http://git.yoctoproject.org/cgit/cgit.cgi/meta-fsl-ppc/log/).


Best Regards,

Zhenhua

From: yocto-boun...@yoctoproject.org [mailto:yocto-boun...@yoctoproject.org] On 
Behalf Of Anicic Damir (PSI)
Sent: Friday, September 23, 2016 10:14 PM
To: yocto@yoctoproject.org
Subject: [yocto] Freescale DPAA drivers

Hi,

I am using Yocto 2.1, PowerPC64, default kernel 4.1.22
Building for T2080rdb.

Everything builds, but kernel is missing DPAA Freescale drivers
(dpaa_eth at least)


It seems that DPAA Freescale drivers not in any Linux kernel (or am I wrong).

Why is that so, is Freescale not planing to include them in kernel ?

Kind regards,

Damir


-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


[yocto] Freescale DPAA drivers

2016-09-23 Thread Anicic Damir (PSI)
Hi,

I am using Yocto 2.1, PowerPC64, default kernel 4.1.22
Building for T2080rdb.

Everything builds, but kernel is missing DPAA Freescale drivers
(dpaa_eth at least)


It seems that DPAA Freescale drivers not in any Linux kernel (or am I wrong).

Why is that so, is Freescale not planing to include them in kernel ?

Kind regards,

Damir



-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


Re: [yocto] build ntp with openssl support

2016-09-23 Thread Oliver Graute
On 22/09/16, Khem Raj wrote:
> On Thu, Sep 22, 2016 at 12:16 AM, Oliver Graute  
> wrote:
> > On 19/09/16, Oliver Graute wrote:
> >> On 16/09/16, Andre McCurdy wrote:
> >> > On Fri, Sep 16, 2016 at 1:24 AM, Oliver Graute  
> >> > wrote:
> >> > > Hello,
> >> > >
> >> > > how can I build ntp with openssl support?
> >> > >
> >> > > I already created a ntp_%.bbappend file to extend the recipe 
> >> > > ntp_4.2.8p4.bb.
> >> > >
> >> > > FILESEXTRAPATHS_prepend := "${THISDIR}/files:"
> >> >
> >> > You don't really need this line unless you are adding a file to
> >> > SRC_URI or replacing a file already in SRC_URI with your own version.
> >> >
> >> > > PACKAGECONFIG += "openssl"
> >> >
> >> > This will enable openssl, but it will also disable all the default
> >> > PACKAGECONFIG options (cap, debug and refclocks) which is probably not
> >> > what you want. Try this instead:
> >> >
> >> >   PACKAGECONFIG_append = " openssl"
> >> >
> >> > Note the space between " and openssl. It's required.
> >>
> >> ok now I see the right configure script options during the configuration
> >> of the ntp build.
> >>
> >> --with-openssl-libdir=/home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/lib
> >> --with-openssl-incdir=/home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/include
> >> --with-crypto
> >>
> >> But ntp is still build without openssl support. The configure scripts
> >> can't find the relevant openssl stuff.
> >>
> >> configure:34762: checking for openssl library directory
> >> configure:34802: result: no
> >> configure:34807: WARNING: libcrypto and libssl not found in any of 
> >> /home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/lib
> >> configure:34811: checking for openssl include directory
> >> configure:34833: result: 
> >> /home/graute/5411_IBIS/yocto/build-imx6ulevk-nand/tmp/sysroots/imx6ulevk/usr/include
> >> configure:34877: checking if we will use crypto
> >> configure:34879: result: no
> >> configure:35109: checking if we want to use OpenSSL's crypto random (if 
> >> available)
> >> configure:35119: result: yes
> >>
> >> some clue whats wrong here?
> >
> > in my sysroots/imx6ulevk/usr/lib I have
> >
> > ls -la libssl*
> >
> > libssl3.so
> > libssl.a
> > libssl.so -> libssl.so.1.0.0
> > libssl.so.1.0.0
> >
> > ls -la libcrypt*
> >
> > libcrypt.a
> > libcrypt_pic.a
> > libcrypt_pic.map
> > libcrypt.so -> ../../lib/libcrypt.so.1
> >
> >
> > but no libcrypto.so. I guess thats the reason why my ntp configure
> > script is complaining.
> >
> > Some ideas how to get libcrypto.so in my /usr/lib folder in the yocto
> > sysroot?
> >
> 
> It seems your openssl is not being compiled correctly. Can you go into
> builddir or openssl
> and see if libcrypto.so.1.0.0 is built ? if not then you have to do
> some digging why its not
> configuring to build libcrypto

libcrypto is build by openssl

openssl/1.0.2d-r0/openssl-1.0.2d$ ls -la  libcrypt*
libcrypto.a
libcrypto.pc
libcrypto.so -> libcrypto.so.1.0.0
libcrypto.so.1.0.0

but in my sysroot libcrypto is located in lib NOT in usr/lib

the ntp recipe in 
meta-openembedded/meta-networking/recipes-support/ntp/ntp_4.2.8p4.bb
defines:

 --with-openssl-libdir=${STAGING_LIBDIR}

I assume I need ${STAGING_BASELIBDIR} here instead. But currently I fail
with overwriting this in my bbappend file.

If I use EXTRA_OECONF to overwrite it in my bbappend I see two 
--with-openssl-libdir
statements while configuring. The first with /lib the second one with /usr/lib. 

EXTRA_OECONF  += "\
--with-openssl \
--with-openssl-libdir=${STAGING_BASELIBDIR} \
--with-openssl-incdir=${STAGING_INCDIR} \
--with-crypto \
"

Best Regards,

Oliver
-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto


[yocto] [meta-security][PATCH] paxctl: allow build of paxctl-native

2016-09-23 Thread wenzong.fan
From: Joe Slater 

paxctl-native is needed to build paxtest.

Do not use the install target in Makefile for paxctl-native, it will
fail with error:

  install: cannot change ownership of '.../sbin/paxctl': \
  Operation not permitted

Signed-off-by: Joe Slater 
Signed-off-by: Wenzong Fan 
---
 recipes-security/paxctl/paxctl_0.9.bb | 15 +++
 1 file changed, 15 insertions(+)

diff --git a/recipes-security/paxctl/paxctl_0.9.bb 
b/recipes-security/paxctl/paxctl_0.9.bb
index d69219f..fb87f10 100644
--- a/recipes-security/paxctl/paxctl_0.9.bb
+++ b/recipes-security/paxctl/paxctl_0.9.bb
@@ -18,3 +18,18 @@ EXTRA_OEMAKE = "CC='${CC}' DESTDIR='${D}'"
 do_install() {
oe_runmake install
 }
+
+# The install target in the Makefile will fail for paxctl-native with error:
+#   install -D --owner 0 --group 0 --mode a=rx paxctl .../sbin/paxctl
+#   install: cannot change ownership of '.../sbin/paxctl': \
+#   Operation not permitted
+# Drop '--owner 0 --group 0' to fix the issue.
+do_install_class-native() {
+   local PROG=paxctl
+   install -d ${D}${base_sbindir}
+   install -d ${D}${mandir}/man1
+   install --mode a=rx $PROG ${D}${base_sbindir}/$PROG
+   install --mode a=r $PROG.1 ${D}${mandir}/man1/$PROG.1
+}
+
+BBCLASSEXTEND = "native"
-- 
2.8.1

-- 
___
yocto mailing list
yocto@yoctoproject.org
https://lists.yoctoproject.org/listinfo/yocto