Description of problem: Mystery solib with macro names in path appears after I open Frinika and create a new project. ~/%{_libdir}/%{_name}/RubberBand-linux-x86.so Version-Release number of selected component (if applicable): frinika-0.6.0-1.fc12.noarch How reproducible: Open Frinika. Start new project. ls ~. Steps to Reproduce: 1. See above. 2. 3. Actual results: See above. Expected results: No mystery solib in homedir. Additional info:
Thanks for the report. I also found a %{_libdir} directory somewhere inside my home directory a while ago but I couldn't figure out what package generated it. Actually the %{_libdir} directory is created where you invoke the "frinika" executable. The bug is in the flexdock package and I am assigning it to its maintainer. The flexdock-jni.patch is wrong. It contains the line: + File file = new File("%{_libdir}/%{name}"); but java does not know about the spec file macros! We shouldn't use these macros in java source files.
D Haley, A possible solution is to replace that line with + File file = new File(System.getProperty("library.directory") + "/flexdock"); and pass a -Dlibrary.directory=%{_libdir} flag to ant.
The patch is correct, what is incorrect is the sed line that modifies the patch in the spec file. I have rebuilt the SRPMs and confirmed that it is working. I will upload to updates shortly.
Just to keep things rolling, here is the patch: --- flexdock.spec 24 Jul 2009 22:53:25 -0000 1.3 +++ flexdock.spec 19 Dec 2009 08:35:10 -0000 @@ -1,6 +1,6 @@ Name: flexdock Version: 0.5.1 -Release: 14%{?dist} +Release: 15%{?dist} Summary: Docking framework for Java Swing GUI apps Group: Development/Libraries @@ -55,18 +55,17 @@ %setup -qc #Modify the jni dir that is hardcoded in the patch -cp -pf %{PATCH0} %{PATCH0}.tmp -sed -i 's!%%{_libdir}/%%{name}/!%{_libdir}/%{name}/!' %{PATCH0} +cp %{PATCH0} ./tmpJniPatch +sed -i 's!%%{_libdir}/%%{name}!%{_libdir}/%{name}!' tmpJniPatch + #Apply patches -%patch0 +#Apply patch0 +patch -p 1 --fuzz=0 < tmpJniPatch %patch1 %patch2 %patch3 %patch4 -#restore patch0 -mv %{PATCH0}.tmp %{PATCH0} - #Override the build file's default hard-coded paths echo "sdk.home=%{_jvmdir}/java" > workingcopy.properties @@ -160,9 +159,11 @@ %changelog +* Sat Dec 19 2009 <mycae(a!t)yahoo.com> 0.5.1-15 +- Fix patch to match sed expression +- Don't modify jni patch in-place * Fri Jul 24 2009 Fedora Release Engineering <rel-eng.org> - 0.5.1-14 - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild - * Sat Mar 28 2009 <mycae(a!t)yahoo.com> 0.5.1-13 - Version bump due to tag mess * Thu Mar 26 2009 <mycae(a!t)yahoo.com> 0.5.1-12
Thanks for the ultra quick fix. Sorry I didn't check the spec file for a sed. One possible trick you could use is to use something fancy like LIBDIRNAME in the patch and sed that string in the spec file. That way you don't have to worry about %'s and /'s. Or one can do the trick in comment #2, which is a quite clean solution without the need to sed the patch.
flexdock-0.5.1-15.fc11 has been pushed to the Fedora 11 testing repository. If problems still persist, please make note of it in this bug report. If you want to test the update, you can install it with su -c 'yum --enablerepo=updates-testing update flexdock'. You can provide feedback for this update here: http://admin.fedoraproject.org/updates/F11/FEDORA-2009-13462
flexdock-0.5.1-15.fc11 has been pushed to the Fedora 11 stable repository. If problems still persist, please make note of it in this bug report.