[opensuse-packaging] EXE-File of mono application is not included in OBS generated package
Hello I try to packaging the mono application Tracer2Server for openSUSE. https://build.opensuse.org/package/show/home:dBruenig:Tracer2Server/Tracer2S... But I still have some issues I don't understand. 1. EXE-File of mono application is not included The generation of i586 package ends with succeeded. But in the RPM file the tracer2server.exe is not included. I don't know way this happens. Because the compilation succeeded (13 warnings). 2. Package generation for x86_64 failed While the generation for i586 succeeded. The generation for x86_64 failed. So where are the difference between these too. I am a newbie in Linux, so please help me to get this working. Regards Dirk -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Thu, Dec 12, 2013 at 3:08 PM, Dirk Brünig
Hello
I try to packaging the mono application Tracer2Server for openSUSE. https://build.opensuse.org/package/show/home:dBruenig:Tracer2Server/Tracer2S... But I still have some issues I don't understand.
1. EXE-File of mono application is not included The generation of i586 package ends with succeeded. But in the RPM file the tracer2server.exe is not included. I don't know way this happens. Because the compilation succeeded (13 warnings).
To be included the binary has to be both built and installed. You say the compile worked, so the install must not have. Your specfile has: ===================================================== %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT #install -m 755 -d $RPM_BUILD_ROOT/%{_sbindir} #ln -s ../bin/trace2server $RPM_BUILD_ROOT/%{_sbindir} ===================================================== It looks you (or someone) tried to explicitly install trace2server, but then changed their mind. That effort may have failed because "ln -s" makes a symbolic link which is not what you want in this case. You want the file to be copied. The typical explicit tool for that would be "install" without the -d argument on the second call. Anyway, either "make install" has to but the binary in the final install location (eg. $RPM_BUILD_ROOT/%{_sbindir}) or you have to do it by calling "install" explicitly.
2. Package generation for x86_64 failed While the generation for i586 succeeded. The generation for x86_64 failed. So where are the difference between these too.
64 bit and 32 bit libraries end up in different directories. Thus %{_libdir} is different based on architecture. I'm guessing that is causing your explicit references to /usr/lib to fail. /usr/lib is the directory for 32-bit libraries thus only 32-bit builds are putting anything there. === %dir /usr/lib/tracer2server /usr/lib/tracer2server/GPL-v2.0.txt /usr/lib/tracer2server/GPL-v3.0.txt /usr/lib/tracer2server/README === The reality is none of those 3 files should be in %{_libdir} (eg. /usr/lib*) anyway. They belong in the documentation support directory. Assuming all 3 of those files are in the root of your tarball you should replace those 4 lines with this I think: === %doc GPL-v2.0.txt GPL-v3.0.txt README %exclude %{_libdir}/tracer2server === The first line will copy the doc files to the right final location and cause them to be included in the RPM. The last line I think will keep the wrongly installed files from being included. Once the RPM builds and you do a test install, you should find the 3 doc files in /usr/share/doc/packages/tracer2server/* I've never known "make install" to put anything in that directory, so if you happen to be the maintainer of the makefile, just quit doing anything with those 3 files. Leave it to the %doc macro to do the magic for you.
I am a newbie in Linux, so please help me to get this working.
Welcome to the community. Greg -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Am 12.12.2013 21:50, schrieb Greg Freemyer:
On Thu, Dec 12, 2013 at 3:08 PM, Dirk Brünig
wrote: Hello
I try to packaging the mono application Tracer2Server for openSUSE. https://build.opensuse.org/package/show/home:dBruenig:Tracer2Server/Tracer2S... But I still have some issues I don't understand.
1. EXE-File of mono application is not included The generation of i586 package ends with succeeded. But in the RPM file the tracer2server.exe is not included. I don't know way this happens. Because the compilation succeeded (13 warnings).
To be included the binary has to be both built and installed. You say the compile worked, so the install must not have.
Your specfile has:
===================================================== %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT
#install -m 755 -d $RPM_BUILD_ROOT/%{_sbindir} #ln -s ../bin/trace2server $RPM_BUILD_ROOT/%{_sbindir} =====================================================
I found this in a spec file some were else.
It looks you (or someone) tried to explicitly install trace2server, but then changed their mind. That effort may have failed because "ln -s" makes a symbolic link which is not what you want in this case. You want the file to be copied. The typical explicit tool for that would be "install" without the -d argument on the second call.
This isn't working. install: missing destination file operand after '/home/abuild/rpmbuild/BUILDROOT/tracer2server-1.2-85.1.i386/usr/sbin'
Anyway, either "make install" has to but the binary in the final install location (eg. $RPM_BUILD_ROOT/%{_sbindir}) or you have to do it by calling "install" explicitly.
Can you give me a more detailed description how this can be done via install. Because the make file is generated by MonoDevelop. And I don't fond a switch to turn it on.
2. Package generation for x86_64 failed While the generation for i586 succeeded. The generation for x86_64 failed. So where are the difference between these too.
64 bit and 32 bit libraries end up in different directories. Thus %{_libdir} is different based on architecture. I'm guessing that is causing your explicit references to /usr/lib to fail. /usr/lib is the directory for 32-bit libraries thus only 32-bit builds are putting anything there.
=== %dir /usr/lib/tracer2server /usr/lib/tracer2server/GPL-v2.0.txt /usr/lib/tracer2server/GPL-v3.0.txt /usr/lib/tracer2server/README ===
The reality is none of those 3 files should be in %{_libdir} (eg. /usr/lib*) anyway. They belong in the documentation support directory. Assuming all 3 of those files are in the root of your tarball you should replace those 4 lines with this I think:
=== %doc GPL-v2.0.txt GPL-v3.0.txt README %exclude %{_libdir}/tracer2server ===
This done it.
The first line will copy the doc files to the right final location and cause them to be included in the RPM. The last line I think will keep the wrongly installed files from being included.
Once the RPM builds and you do a test install, you should find the 3 doc files in /usr/share/doc/packages/tracer2server/*
I've never known "make install" to put anything in that directory, so if you happen to be the maintainer of the makefile, just quit doing anything with those 3 files. Leave it to the %doc macro to do the magic for you.
I am a newbie in Linux, so please help me to get this working.
Welcome to the community.
Greg
-- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Dnia sobota, 14 grudnia 2013 11:06:50 Dirk Brünig pisze:
Can you give me a more detailed description how this can be done via install. Because the make file is generated by MonoDevelop. And I don't fond a switch to turn it on.
Can you ask a Mono expert instead. Best regards, Chris -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Sat, Dec 14, 2013 at 5:06 AM, Dirk Brünig
Am 12.12.2013 21:50, schrieb Greg Freemyer:
On Thu, Dec 12, 2013 at 3:08 PM, Dirk Brünig
wrote: Hello
I try to packaging the mono application Tracer2Server for openSUSE.
https://build.opensuse.org/package/show/home:dBruenig:Tracer2Server/Tracer2S... But I still have some issues I don't understand.
1. EXE-File of mono application is not included The generation of i586 package ends with succeeded. But in the RPM file the tracer2server.exe is not included. I don't know way this happens. Because the compilation succeeded (13 warnings).
To be included the binary has to be both built and installed. You say the compile worked, so the install must not have.
Your specfile has:
===================================================== %install rm -rf $RPM_BUILD_ROOT make install DESTDIR=$RPM_BUILD_ROOT
#install -m 755 -d $RPM_BUILD_ROOT/%{_sbindir} #ln -s ../bin/trace2server $RPM_BUILD_ROOT/%{_sbindir} =====================================================
I found this in a spec file some were else.
It looks you (or someone) tried to explicitly install trace2server, but then changed their mind. That effort may have failed because "ln -s" makes a symbolic link which is not what you want in this case. You want the file to be copied. The typical explicit tool for that would be "install" without the -d argument on the second call.
This isn't working. install: missing destination file operand after '/home/abuild/rpmbuild/BUILDROOT/tracer2server-1.2-85.1.i386/usr/sbin'
Anyway, either "make install" has to but the binary in the final install location (eg. $RPM_BUILD_ROOT/%{_sbindir}) or you have to do it by calling "install" explicitly.
Can you give me a more detailed description how this can be done via install. Because the make file is generated by MonoDevelop. And I don't fond a switch to turn it on.
If you're going to package RPMs for openSUSE (or any linux) you will need to learn to read a man page (eg. man install) In this case this might work for you: #create the /usr/sbin directory install -m 755 -d $RPM_BUILD_ROOT/%{_sbindir} # put trace2server in /usr/sbin install -m 744 ../bin/trace2server $RPM_BUILD_ROOT/%{_sbindir} I picked 744 because 7 means read/write/execute for "root". The 4's mean read only for group and all. If this is going into /usr/sbin, then I assume it should be executable by root only. If it is should be executable by all, then it should go into %{_bindir} and have permissions 755. Also, I'm just assuming that ../bin/trace2server is the right place to find the pre-installed copy. Greg -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Hello, Am Samstag, 14. Dezember 2013 schrieb Greg Freemyer:
# put trace2server in /usr/sbin install -m 744 ../bin/trace2server $RPM_BUILD_ROOT/%{_sbindir}
I picked 744 because 7 means read/write/execute for "root". The 4's mean read only for group and all. If this is going into /usr/sbin, then I assume it should be executable by root only. If it is should be executable by all, then it should go into %{_bindir} and have permissions 755.
Please avoid using 744 permissions (in fact, I typically open a bugreport if I see this permission set ;-) If the binary should be executable for everybody (even if it only prints "you must be root to run me"), it should have 755. Otherwise, 700 is enough - if a user isn't allowed to execute it, read permissions don't really make sense IMHO ;-) (besides that, /usr/sbin/ is usually not in the user's path - which means he'll explicitely have to type "/usr/sbin/trace2server" if he really wants to run it) Regards, Christian Boltz --
Ohh jee ... ich will mein yast1 wieder *heul* :-)) Ich hab's noch, ich hab's noch... *freu* *hüpf* *SuSE 7.3 behalt* Bleib mir weg mit deiner neumodischen 7.sonstwas! [>> Konrad Neitzel, > Florian Gross und David Haller in suse-linux]
-- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Sunday 2013-12-15 01:30, Christian Boltz wrote:
Please avoid using 744 permissions (in fact, I typically open a bugreport if I see this permission set ;-)
If the binary should be executable for everybody (even if it only prints "you must be root to run me"), it should have 755.
Otherwise, 700 is enough - if a user isn't allowed to execute it, read permissions don't really make sense IMHO ;-)
Keeping read permissions from the user is quite useless too: you could just grab the RPM from an FTP and extract it to look at it. In other words, just set all x bits. Unless it is a SUID/SGID program, all users being able to execute it does not make a situation worse. -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
On Thursday 2013-12-12 21:08, Dirk Brünig wrote:
1. EXE-File of mono application is not included The generation of i586 package ends with succeeded. But in the RPM file the tracer2server.exe is not included. I don't know way this happens.
Because `make install` did not install it, because the Makefiles in the project never specified to install anything.
2. Package generation for x86_64 failed
See the build log: [ 128s] File not found: /home/abuild/rpmbuild/BUILDROOT/tracer2server-1.2-69.1.x86_64/usr/lib/tracer2server/README -- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
Am 12.12.2013 21:56, schrieb Jan Engelhardt:
On Thursday 2013-12-12 21:08, Dirk Brünig wrote:
1. EXE-File of mono application is not included The generation of i586 package ends with succeeded. But in the RPM file the tracer2server.exe is not included. I don't know way this happens.
Because `make install` did not install it, because the Makefiles in the project never specified to install anything.
The make file is generated by the MonoDevelop IDE. Is there another way to do it, because inside the IDE I can't find a option to switch this on.
2. Package generation for x86_64 failed
See the build log:
[ 128s] File not found: /home/abuild/rpmbuild/BUILDROOT/tracer2server-1.2-69.1.x86_64/usr/lib/tracer2server/README
-- To unsubscribe, e-mail: opensuse-packaging+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse-packaging+owner@opensuse.org
participants (5)
-
Christian Boltz
-
Dirk Brünig
-
Greg Freemyer
-
Jan Engelhardt
-
Křištof Želechovski