Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Fri 29 Aug 2014, 04:11
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
src2pkg-2.7 - create packages from any source code
Post new topic   Reply to topic View previous topic :: View next topic
Page 3 of 4 [56 Posts]   Goto page: Previous 1, 2, 3, 4 Next
Author Message
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Tue 21 Feb 2012, 16:14    Post subject:  

Yes, thank you. I'll see about morphing that into a puppy-specific extension for src2pkg and then everyone can be happy with more complete *.specs files.
Back to top
View user's profile Send private message 
Keef


Joined: 20 Dec 2007
Posts: 622
Location: Staffordshire

PostPosted: Sun 26 Feb 2012, 18:37    Post subject:  

I've just tried to install the pet on Akita (beta 7), but it fails when trying to compile libsentry. Tried running make on libsentry (in the src2pkg-helpers dir), and got the following result:
Code:

# make
cc -Wall -U_FORTIFY_SOURCE -D_GNU_SOURCE -DLIBDIR=\"/usr/local/lib\" -DPIC -fPIC -D_REENTRANT -DVERSION=\"0.7.0\" -c libsentry.c
libsentry.c:3090: error: conflicting types for 'scandir'
/usr/include/dirent.h:254: error: previous declaration of 'scandir' was here
libsentry.c:3743: error: conflicting types for 'scandir64'
/usr/include/dirent.h:275: error: previous declaration of 'scandir64' was here
make: *** [libsentry.o] Error 1



It has worked ok for me on Fire Hydrant Lite 301 RetroV3, and SolidPup (Wary 511).
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Mon 27 Feb 2012, 04:24    Post subject:  

Ay, Ay, Ay, that old problem -it's a glibc thing, where it is declared differently in different versions.
What version of gcc do you have ( output from running: gcc -dumpversion)?
What version of glibc do you have (output from running: /lib/libc.so.6)?
Back to top
View user's profile Send private message 
Keef


Joined: 20 Dec 2007
Posts: 622
Location: Staffordshire

PostPosted: Mon 27 Feb 2012, 15:05    Post subject:  

Amigo,

Here are the gory details:

gcc version is 4.2.2
Code:

# /lib/libc.so.6
GNU C Library stable release version 2.10.1, by Roland McGrath et al.
Copyright (C) 2009 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.
Compiled by GNU CC version 4.3.4.
Compiled on a Linux >>2.6.32.16<< system on 2010-09-13.
Available extensions:
        crypt add-on version 2.1 by Michael Glad and others
        Native POSIX Threads Library by Ulrich Drepper et al
        Support for some architectures added on, not maintained in glibc core.
        BIND-8.2.3-T5B

EDIT I've had a PM from scottman about this, with a possible solution. Will update when I've tried it.
Back to top
View user's profile Send private message 
Tman


Joined: 22 Jan 2011
Posts: 814
Location: Toronto

PostPosted: Tue 28 Feb 2012, 13:06    Post subject:  

Hi Amigo,

When src2pkg creates a pet from a source on my hard-drive, the pet contains the proper tree structure to files and folders but it contains a secondary tree where all of the files are duplicated inside of a folder named initrd. I was wondering if there is a way to avoid this?

Last edited by Tman on Tue 28 Feb 2012, 13:07; edited 1 time in total
Back to top
View user's profile Send private message 
Tman


Joined: 22 Jan 2011
Posts: 814
Location: Toronto

PostPosted: Tue 28 Feb 2012, 13:07    Post subject:  

removed double post
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Tue 28 Feb 2012, 13:09    Post subject:  

Keef, Notice this:
gcc version is 4.2.2
and this?:
Compiled by GNU CC version 4.3.4
May be part of the problem. There is a small patch that is used in the libsentry sources which needs to be removed or applied -mostly depending on the glibc version. It comes applied with the latest versions of src2pkg, but maybe I need more 'ifs' in the code somewhwere to try to get it right for everybody. Your feedback is useful. But that version mis-match you have there is not a good sign... Puppy is infamous for its' wacky, unclean toolchains...
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Tue 28 Feb 2012, 13:14    Post subject:  

Tman, what software are you trying to build. I have never seen a report of this problem for Puppy -it's a very good sign that at least examine the contents of a potential package.

The specific software you are building may have something to do with this, but I may have to build in a special work-around for this situation.
Please cd into the package dir where the content it and run 'find > files.txt'
The cd into your /initrd dir and do the same, then post the results.

If you are running from hard drive, why is there still an /initrd dir around anyway?
Back to top
View user's profile Send private message 
Tman


Joined: 22 Jan 2011
Posts: 814
Location: Toronto

PostPosted: Tue 28 Feb 2012, 13:54    Post subject:  

I don't think that the reason is becuase of the sources. When I last compiled Thunar for dpup Exprimo, Thunar and all of the dependency pets contained 2 trees.

I don't know if it has anything to do with how I set up my hard-drives.
My first hard-drive has Windows XP and a secondary Linux partition which I plan to install debian onto.

The second hard-drive has a Windows7 partition, another ntfs partition for storage, and the third ext4 partition for frugal pups.

I download the sources to my /mnt/home (2nd hard-drive), which is an ext4 partition.

The reason why I download the sources first is because I extract them and run ./configure --help to see all of the options. I next type in all of the options that I want into a text file, which I later paste into LXTerminal when running src2pkg.
Back to top
View user's profile Send private message 
Tman


Joined: 22 Jan 2011
Posts: 814
Location: Toronto

PostPosted: Tue 28 Feb 2012, 14:16    Post subject:  

amigo wrote:

Please cd into the package dir where the content it and run 'find > files.txt'


I quickly recompiled jwm which I tried before, but deleted after.
Code:

cd /mnt/home
src2pkg -VV jwm-2.1.0.tar.bz2


Below is the contents of the files.txt with the contents of the normal tree and the initrd tree.
Code:

.
./files.txt
./jwm-2.1.0-i486-1
./jwm-2.1.0-i486-1/initrd
./jwm-2.1.0-i486-1/initrd/mnt
./jwm-2.1.0-i486-1/initrd/mnt/dev_save
./jwm-2.1.0-i486-1/initrd/mnt/dev_save/jwm-2.1.0-src-1
./jwm-2.1.0-i486-1/initrd/mnt/dev_save/jwm-2.1.0-src-1/src
./jwm-2.1.0-i486-1/initrd/mnt/dev_save/jwm-2.1.0-src-1/src/jwm
./jwm-2.1.0-i486-1/usr
./jwm-2.1.0-i486-1/usr/etc
./jwm-2.1.0-i486-1/usr/etc/system.jwmrc
./jwm-2.1.0-i486-1/usr/share
./jwm-2.1.0-i486-1/usr/share/man
./jwm-2.1.0-i486-1/usr/share/man/man1
./jwm-2.1.0-i486-1/usr/share/man/man1/jwm.1
./jwm-2.1.0-i486-1/usr/man
./jwm-2.1.0-i486-1/usr/man/man1
./jwm-2.1.0-i486-1/usr/man/man1/jwm.1.gz
./jwm-2.1.0-i486-1/usr/doc
./jwm-2.1.0-i486-1/usr/doc/jwm-2.1.0
./jwm-2.1.0-i486-1/usr/doc/jwm-2.1.0/jwm.desc
./jwm-2.1.0-i486-1/usr/doc/jwm-2.1.0/LICENSE
./jwm-2.1.0-i486-1/usr/doc/jwm-2.1.0/README
./jwm-2.1.0-i486-1/usr/bin
./jwm-2.1.0-i486-1/usr/bin/jwm


??. I guess I was wrong about the initrd tree duplicating everything. In this instance, it only contains the jwm binary.
Back to top
View user's profile Send private message 
Tman


Joined: 22 Jan 2011
Posts: 814
Location: Toronto

PostPosted: Tue 28 Feb 2012, 14:37    Post subject:  

Btw.. I didn't attach the file.txt for the Thunar and its dependency pets becuase I altered them and deleted the original pets.
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Tue 28 Feb 2012, 16:03    Post subject:  

dev_save -there's the problem. I'm afraid I'll have to look at a fix for this tomorrow as it is getting late here. It would help if you post the output from scr2pkg when you run this build. What I'm looking for is what comes just after this line in the output:
Compiling has been - Successful!"
Make sure you are not using the '-VV' option or the line will be lost.

No wait, here's a fix for it. Open the file /usr/libexec/src2pkg/08-fake_install and scroll down to line 303:
"post_fake_install() {"
Place the cursor at the end of that line, hit ENTER and then paste this in there:
Code:
   if [[ -d "$PKG_DIR"/initrd ]] ; then
      ( cd "$PKG_DIR" && rm -rf initrd )
   fi

There's already a general fix-up routine there which covers all content-creation types, so it should be fine there.
Back to top
View user's profile Send private message 
Tman


Joined: 22 Jan 2011
Posts: 814
Location: Toronto

PostPosted: Tue 28 Feb 2012, 16:37    Post subject:  

Thanks, very much, amigo.Smile
Your patch fixed the issue in the pet. It is still creating the initrd folder, but your patch removes it.

I here is the output from src2pkg as you requested earlier:
Code:

Compiling has been - Successful!
Checking for Makefile rule: 'install' Okay
Checking support for DESTDIR (or similar) - Not found
   Notice - DESTDIR support not found. Falling back to JAIL install
Creating content in JAIL root - Using: 'make install'
cd src ; make all
make[1]: Entering directory `/initrd/mnt/dev_save/jwm-2.1.0-src-1/src'
make[1]: Nothing to be done for `all'.
make[1]: Leaving directory `/initrd/mnt/dev_save/jwm-2.1.0-src-1/src'
cd src ; make install ; cd ..
make[1]: Entering directory `/initrd/mnt/dev_save/jwm-2.1.0-src-1/src'
strip jwm
install -d /usr/bin
install jwm /usr/bin/jwm
make[1]: Leaving directory `/initrd/mnt/dev_save/jwm-2.1.0-src-1/src'
install -d /usr/etc
install -m 644 example.jwmrc /usr/etc/system.jwmrc
install -d /usr/share/man/man1
install -m 644 jwm.1 /usr/share/man/man1/jwm.1
   Notice - Checking integrity of '' installation - Done
Safe content creation - Successful!
Processing package content:
Correcting package permissions - Done
Stripping ELF binaries - Using: strip -p --strip-unneeded Done
Checking for standard documents - Done
   NOTICE - No man-pages installed by Makefile
Found man-pages in SRC_DIR - Installing in PKG_DIR
Compressing man pages - Done
Creating slack-desc - From default text
Rechecking package correctness:
Checking for misplaced dirs - Done
Rechecking package permissions - Done
Checking for dead links in PKG_DIR - Done
Searching for links in: jwm-2.1.0-i486-1 - None found
Creating package: 'jwm-2.1.0-i486-1.pet' - Done
Package Creation - Successful! Package location:
/mnt/home/jwm-2.1.0-i486-1.pet
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Wed 29 Feb 2012, 03:47    Post subject:  

"Creating content in JAIL root" is what I was looking for -as I thought I'd have to code something for each type of content-creation.

"It is still creating the initrd folder" -I'll fix this a different way for next version which should avoid it being created at all.
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2236

PostPosted: Wed 29 Feb 2012, 06:21    Post subject:  

Keef, I need to see a copy of a header on your system:
/usr/include/dirent.h
Either paste inside code tags here, or attach it please. I'm pretty sure there is a mis-match between that header and the version used when glibc was compiled. When src2pkg tries to compile libsentry, the libsentry 'make' process tries to figure out which syntax to use for the 'scandir' function among others. The glibc version is read directly to figure this out. A new syntax is used for glibc >= 2.10, so it should be working. But that syntax should also match in the 'kernel headers' which were used to define the glibc kernel interface when glibc was compiled. If they don't compiling *lots* of things will fail.

I'm pretty sure that I can't really fix this in the libsentry make process. If I have it read the scandir syntax from the header, instead of from implying from the glibc version, I think the library would compile, but then segfault when you run it. Could you perhaps try some other distro with a 'sane' toolchain? No, I didn't really mean that did I?
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 3 of 4 [56 Posts]   Goto page: Previous 1, 2, 3, 4 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Utilities
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0898s ][ Queries: 13 (0.0055s) ][ GZIP on ]