Bug 608069 - Review Request: tango - standard library for D language of d1 specification
Review Request: tango - standard library for D language of d1 specification
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: Package Review (Show other bugs)
13
All Linux
low Severity medium
: ---
: ---
Assigned To: Peter Robinson
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2010-06-25 11:14 EDT by MERCIER Jonathan
Modified: 2010-09-07 02:49 EDT (History)
8 users (show)

See Also:
Fixed In Version: tango-0.99.9-15.20100802svn5517.fc14
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2010-08-10 17:32:12 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
pbrobinson: fedora‑review+
kevin: fedora‑cvs+


Attachments (Terms of Use)

  None (edit)
Description MERCIER Jonathan 2010-06-25 11:14:03 EDT
Spec url:
http://bioinfornatics.fedorapeople.org/tango.spec

Src.rpm url:
http://bioinfornatics.fedorapeople.org/tango-0.99.9-1.20102406svn5487.fc13.src.rpm


$ rpmlint -i SPECS/tango.spec 
SPECS/tango.spec: W: invalid-url Source0: tango-20102406svn5487.tar.xz
The value should be a valid, public HTTP, HTTPS, or FTP URL.

0 packages and 1 specfiles checked; 0 errors, 1 warnings.
_____________________________________________________________________________
$ rpmlint -i SRPMS/tango-0.99.9-1.20102406svn5487.fc13.src.rpm => wrong misspeling
warning and:
tango.src: W: invalid-url Source0: tango-20102406svn5487.tar.xz
The value should be a valid, public HTTP, HTTPS, or FTP URL.

upstream fix lot of bug

Note currently for D language they use static library, for shared library they said "because D likes static, it is actually a bit complicated to have shared libs"
from a discuss in IRC freenode #ldc
Comment 1 Michael Scherer 2010-06-29 18:00:24 EDT
First, sorry if I seems to be nitpicking, but that catched my eyes :

- the comment about hg is wrong, as you use svn. ( line 4 )

- Summary could be improved, I think it is weird to have a complete sentence there. Same goes for examples subpackage, and some others parts of %description

- in %setup, you remove some binary build directory, what is the reason ? If other directories appears there in the futur, should they be removed too ? Maybe they could be removed directly from the tarball ?

- can you explain the line about infinite loop in %build ?

- the french description could be improved, IMHO.

- the buildsystem seems to use directly a binary ( bob ), and they store the binary in svn directly. This seems bad, as we cannot inspect of fix anything. Wouldn't it be better to regenerate the binary using the source and the script ? I think the issue have been discussed in the past on fedora-devel, but I am not sure about the conclusion, so disregard my comment if I was wrong.
Comment 2 MERCIER Jonathan 2010-06-29 19:46:18 EDT
file are updated here: http://bioinfornatics.fedorapeople.org/

(In reply to comment #1)
> First, sorry if I seems to be nitpicking, but that catched my eyes :
> 
> - the comment about hg is wrong, as you use svn. ( line 4 )

true, sorry is fixed

(In reply to comment #1)
> - Summary could be improved, I think it is weird to have a complete sentence
> there. Same goes for examples subpackage, and some others parts of %description

Done

(In reply to comment #1)
> - in %setup, you remove some binary build directory, what is the reason ? If

this file are never used:
- /core/rt/compiler/dmd is for dmd compiler but is not open source
- /core/rt/compiler/gdc if for gdc compiler this project are a low activity
and is only for d1 revision for this reason i do'nt package it (instead ldc who work on d1 and d2).

(In reply to comment #1)
> other directories appears there in the futur, should they be removed too ?
> Maybe they could be removed directly from the tarball ?

will see

> - can you explain the line about infinite loop in %build ?
i try compil with 03 and 02 optimization but fail


> - the french description could be improved, IMHO.

Done

> - the buildsystem seems to use directly a binary ( bob ), and they store the
> binary in svn directly. This seems bad, as we cannot inspect of fix anything.
> Wouldn't it be better to regenerate the binary using the source and the script
> ? I think the issue have been discussed in the past on fedora-devel, but I am
> not sure about the conclusion, so disregard my comment if I was wrong.    

use ruby script instead binary
Comment 3 MERCIER Jonathan 2010-07-04 08:01:49 EDT
(In reply to comment #1)
> other directories appears there in the futur, should they be removed too ?

rpmlint say nothing about this so i think is good
Comment 4 Mohamed El Morabity 2010-07-05 19:31:48 EDT
ruby (at least) is a missing BuildRequires.
Moreover, the script ./build/script/bob.rb called to compile tango is completely silent. Could you make it more verbose ?
Comment 5 Chen Lei 2010-07-08 09:17:10 EDT
It'll be better to install examples to %{_docdir}.

See https://fedoraproject.org/wiki/Packaging_tricks#Examples
Comment 6 MERCIER Jonathan 2010-07-12 15:23:38 EDT
thanks for this macro (i did not know)
spec anr src.rpm are updated:
- http://bioinfornatics.fedorapeople.org/tango.spec
- http://bioinfornatics.fedorapeople.org/tango-0.99.9-1.3.20102406svn5487.fc13.src.rpm
Comment 7 Chen Lei 2010-07-23 13:17:38 EDT
Some initial comments:
1.
%global     alphatag        20101207
->%global     alphatag        20100712
See https://fedoraproject.org/wiki/Packaging:NamingGuidelines#Snapshot_packages
2.
ExcludeArch:    sparc
->ExcludeArch:    %sparc
rpm --eval %sparc
sparc sparcv8 sparcv9 sparcv9v sparc64 sparc64v
3.
Group:          Development/Languages
I think Gourp should be Development/Libraries, Development/Languages is compliler or runtime only(e.g. gcc perl jdk gfortran).

4.
%files
%defattr(-,root,root,-)
%doc README.txt LICENSE.txt 
%{_libdir}/%{name}/libtango.a
Those files should be removed to -devel subpackage,main package is meaningless. Also, you also add Provides: %{name}-static to -devel subpackage.

See https://fedoraproject.org/wiki/Packaging:Guidelines#Packaging_Static_Libraries_2

5.
%files documentation
%defattr(-,root,root,-)
%doc doc/example
%files examples
%defattr(-,root,root,-)
%doc  doc/html/

-documention should be renamed to -doc subpackage, if it's not big enough, it can also be merged to -devel subpackage. If -examples subpackage is not big enough, you can merge it to -devel or -doc subpackage.

cp -rp doc/html/*       %{buildroot}%{_defaultdocdir}/%{name}-%{version}/doc
cp -rp doc/example/*    %{buildroot}%{_defaultdocdir}/%{name}-%{version}/examples/
See
https://fedoraproject.org/wiki/Packaging:Guidelines#Documentation
https://fedoraproject.org/wiki/Packaging_tricks#Examples
Comment 8 MERCIER Jonathan 2010-07-23 13:43:30 EDT
thanks chen lei,
i check size and:
$ du -h -s /usr/share/doc/tango-examples-0.99.9/
161K	/usr/share/doc/tango-examples-0.99.9/

$ du -h -s /usr/share/doc/tango-documentation-0.99.9/
565K	/usr/share/doc/tango-documentation-0.99.9/

is enough for a sub package or not?
Comment 9 Chen Lei 2010-07-24 07:06:46 EDT
(In reply to comment #8)
> thanks chen lei,
> i check size and:
> $ du -h -s /usr/share/doc/tango-examples-0.99.9/
> 161K /usr/share/doc/tango-examples-0.99.9/
> $ du -h -s /usr/share/doc/tango-documentation-0.99.9/
> 565K /usr/share/doc/tango-documentation-0.99.9/
> is enough for a sub package or not?    

I think it's safe to include examples and docs in -devel subpackage, most of D developers may need those docs.

One question:

Do binaries compiled with ldc support GNU strip? rpmbuild will strip all binaries automatically with executable bit.
Comment 10 MERCIER Jonathan 2010-07-24 08:16:54 EDT
yes ldc support GNU strip.
Comment 11 MERCIER Jonathan 2010-07-24 09:29:44 EDT
I had updated spec and src.rpm. Can you check for static library id is the good way. It is the first time where i build static libraries only (not my first package).

Link:
http://bioinfornatics.fedorapeople.org/tango-0.99.9-6.20100720svn5505.fc13.src.rpm

http://bioinfornatics.fedorapeople.org/tango.spec

Thanks
Comment 12 Chen Lei 2010-07-24 11:21:19 EDT
From some documents and debian packages, I found that tango package includes two libs - libtango-user.a and libtango-base.a, are those two libs merged to single libtango.a now?

Another issues should be addressed in the future is all D programs should be compiled with a unified DFLAGS like %{optflags} for C/C++/Fortran programs. 

rpm --eval %optflags
-O2 -g -pipe -Wall -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector --param=ssp-buffer-size=4 -m64 -mtune=generic

See http://fedoraproject.org/wiki/Packaging/Guidelines#Compiler_flags
Comment 13 MERCIER Jonathan 2010-07-24 11:38:16 EDT
now they are one libs

yeah sure this macro will be usefull, i will work on.
Comment 14 Chen Lei 2010-07-24 11:44:51 EDT
(In reply to comment #13)
> now they are one libs
> yeah sure this macro will be usefull, i will work on.    

It's not a review blocker, those macros can be addressed in the future(maybe F15+).
Comment 15 MERCIER Jonathan 2010-07-24 11:54:33 EDT
thanks,
I work on for this feature, i will create http://fedoraproject.org/wiki/Packaging:D
Comment 16 Juan Castro 2010-07-24 14:32:35 EDT
I rpmbuild-ed and installed the most recent srpms for ldc and tango from http://bioinfornatics.fedorapeople.org ...

$ rpm -q ldc tango tango-devel
ldc-0.9.2-2.20100706hg1653.fc13.i686
tango-0.99.9-1.4.20101207svn5498.fc13.i686
tango-devel-0.99.9-1.4.20101207svn5498.fc13.i686

...but when I try to compile a d program I get this:

$ ldc hello.d 
hello.d(1): Error: module stdio cannot read file 'std/stdio.d'

hello.c: ---------------------
import std.stdio;

void main()
{
	writeln("Hello, world!");
}
------------------------------
Comment 17 MERCIER Jonathan 2010-07-24 16:25:25 EDT
tango is not phobos

see this example:
module test;
import tango.stdc.stdio;
import tango.io.Console			: Cout, Cerr;
import tango.io.Stdout;
import tango.text.convert.Format;
import tango.text.convert.Integer	: format;

void main(){
	uint a = 5;
	uint b = 0;
	char[1] tmp0;
	char[1] tmp1;
	//printf same in C
	printf("hello, world\n");
	//Cout same in C++
	Cout("try divide ")(format(tmp0, a, "d"))(" by ")(format(tmp1, b, "d")).newline;
	//test
	if (b == 0){
		Cerr("Divide by zero!!").newline;
	}
	else{
		Format("Result: {}\n", a/b);
		Stdout.formatln ("Result: '{}'/'{}'='{}'", a, b, a/b);
	}
}
Comment 18 MERCIER Jonathan 2010-07-24 16:35:31 EDT
shorter example:
________________________________________
module test;
import tango.io.Stdout: Stdout, Stderr;

void main(){
	uint a = 5;
	uint b = 0;
	//printf same in C
	Stdout.formatln("hello, world");
	//Cout same in C++
	Stdout.formatln("try divide '{}' by '{}'",  a, b);
	//test
	if (b == 0){
		Stderr.formatln("Divide by zero!!");
	}
	else{
		Stdout.formatln("Result: '{}'", a/b);
		Stdout.formatln("Result: '{}'/'{}'='{}'", a, b, a/b);
	}
}
Comment 19 MERCIER Jonathan 2010-07-24 16:37:43 EDT
I forgot to remove the comments: //printf same in C And //Cout same in C++
Comment 20 Chen Lei 2010-07-25 03:39:57 EDT
Some more comments:
1.License:        AFL and BSD
Please recheck this license and add a comments if it's really a Multiple Licensing Scenarios rather than Dual Licensing Scenarios 
http://fedoraproject.org/wiki/Packaging/LicensingGuidelines#Dual_Licensing_Scenarios
2.
%prep
%setup -q -n %{name}-%{alphatag}%{svn_revision}
rm -rf ./build/bin/freebsd32
rm -rf ./build/bin/osx32
rm -rf ./build/bin/win32
Please remove all binaries in %prep.

rm -rf ./build/bin/*
3.

rm -rf      %{name}/core/rt/compiler/gdc 
rm -rf      %{name}/core/rt/compiler/dmd

I wonder if it's safe to remove %{name}/core/rt/ completely here, offical tango tarball don't include those files.
See http://www.dsource.org/projects/tango/wiki/TopicInstallTangoLdc

4.

cp -rp object.di        %{buildroot}%{_includedir}/d/%{name}/
->cp -rp object.di        %{buildroot}%{_includedir}/d

5.

%files
%defattr(-,root,root,-)
%doc README.txt LICENSE.txt 
%{_libdir}/%{name}/libtango.a
%files devel
%defattr(-,root,root,-)
%doc doc/example doc/html/
%{_includedir}/d/%{name}
->

%files devel
%defattr(-,root,root,-)
%doc README.txt LICENSE.txt
%doc doc/example doc/html/
%{_libdir}/%{name}/libtango.a
%{_includedir}/d/%{name}
Comment 21 MERCIER Jonathan 2010-07-25 07:45:30 EDT
1/ yes is Multiple license
http://www.dsource.org/projects/tango/wiki/LibraryLicense

2/ ok i will do

3/ remove files %{name}/core/rt/compiler/[gdc|dmd] it is not used for build tango with ldc.

4/ why put object.di out of tango directory?

5 ok i will do
Comment 22 Chen Lei 2010-07-25 08:11:52 EDT
(In reply to comment #21)
> 1/ yes is Multiple license
> http://www.dsource.org/projects/tango/wiki/LibraryLicense

So you need to use 'or' instead of 'and' in license field.


> 3/ remove files %{name}/core/rt/compiler/[gdc|dmd] it is not used for build
> tango with ldc.
Can we remove the whole %{name}/core/rt directory in %install section, are  files under %{name}/core/rt/ldc compiled into libtango.a? It seems upstream tarballs don't include %{name}/core/rt.

> 4/ why put object.di out of tango directory?
Upstream tarballs and other distribution put object.di outside tango dir. It'll be better to keep close with upstream.

See 

http://downloads.dsource.org/projects/tango/0.99.9/tango-0.99.9-bin-linux32-ldc.tar.gz
http://downloads.dsource.org/projects/tango/0.99.9/tango-0.99.9-bin-linux64-ldc.tar.gz
Comment 23 MERCIER Jonathan 2010-07-25 08:49:57 EDT
ok for 1 and 2

3/ yes we can remove this directory, but if someone want look these module for any thing, he will need take subversion release (why not?)
how you want
Comment 24 MERCIER Jonathan 2010-07-25 08:50:45 EDT
is 1/ and 4/
Comment 26 Juan Castro 2010-07-26 00:04:31 EDT
Ah, your example worked OK.

Jonathan, I'm trying to learn the language D through Alexei Alexandrescu's book. In fact, I just started reading the first sample chapter through Google Books and am deciding whether I'll buy it or not. Clearly, it uses another runtime library in its examples. In your opinion, is this still a good course of action?

Also, if this dialog is more appropriate for another channel of communication (i.e. mailing lisk or the like), please advise.
Comment 27 MERCIER Jonathan 2010-07-27 08:40:11 EDT
hello,
I write here for everybody who has same question, but is last time (i no idea where is the best channel of communication)

if you want learn D:
- read source file (/usr/include/d) -> contains documentation and unit test is usefull for learn how it works
- irc:
freenode => #d and #d.tango
- book:
 * http://www.dsource.org/projects/tango/wiki/LearnToTangoWithD
- tango API: http://www.dsource.org/projects/tango/docs/stable
- tango example: http://www.dsource.org/projects/tango/wiki/Examples
- tango tutorial: http://www.dsource.org/projects/tango/wiki/Tutorials
- tango general: http://www.dsource.org/projects/tango
Comment 28 MERCIER Jonathan 2010-07-27 09:42:31 EDT
you can mail me if you are some other question i will ytry help you ;)
Comment 29 MERCIER Jonathan 2010-07-27 10:16:14 EDT
i add just add a new package for D user: https://bugzilla.redhat.com/show_bug.cgi?id=618668
this one allow use openGL in D application
Comment 30 Chen Lei 2010-07-29 06:11:15 EDT
(In reply to comment #23)
> ok for 1 and 2
> 
> 3/ yes we can remove this directory, but if someone want look these module for
> any thing, he will need take subversion release (why not?)
> how you want    

If those files are compiled into libtango.a, then you don't need to include them in the rpm, most C/C++ static library packages only includes headers and static libraries.

Installing static libraries to %{_libdir}%{name} seems not appropriate, if we have a lot of D libraries, we have to set a lot of linking paths in ldc.conf.
I suggest to install all D static libraries to %{_libdir}(like all other C/C++ fortran libraries) or %{_libdir}/d(like debian/ubuntu). I suggest you to discuss this with tango upstream.

==
Comment 31 MERCIER Jonathan 2010-07-29 09:14:13 EDT
i discuss with tango upstream and we choose %{_libdir}/d
http://bioinfornatics.fedorapeople.org/tango-0.99.9-9.20100726svn5508.fc13.src.rpm
http://bioinfornatics.fedorapeople.org/tango.spec

i create new macro for D:
# Include directory where all .di or .d file are installed.
%_d_includedir %{_includedir}/d
# Compile options for ldc and make file
%_d_optflags -release -w -g
# Lib directory path
%_d_libdir %{_libdir}/d

this macro is in ldc package dvc is down today):
- 32:
http://bioinfornatics.fedorapeople.org/ldc-0.9.2-9.20100609hg1653.fc13.i686.rpm
- 64:
http://bioinfornatics.fedorapeople.org/ldc-0.9.2-9.20100609hg1653.fc13.x86_64.rpm
Comment 32 MERCIER Jonathan 2010-07-29 09:14:56 EDT
s/dvc/cvs/
Comment 33 MERCIER Jonathan 2010-07-31 10:13:01 EDT
hello,
chean lei can you finish this release please, this is very important.
Alpha freeze is already do and this last feature is not done.
this review need be done this week or monday.
Please
thanks for all
best regards
Comment 34 MERCIER Jonathan 2010-07-31 10:13:43 EDT
Chen Lei (sorry)
Comment 35 Peter Robinson 2010-08-01 08:21:55 EDT
I'll do this one today.
Comment 36 Chen Lei 2010-08-01 09:33:09 EDT
(In reply to comment #33)
> hello,
> chean lei can you finish this release please, this is very important.
> Alpha freeze is already do and this last feature is not done.
> this review need be done this week or monday.
> Please
> thanks for all
> best regards    

Sorry, I don't have enough time to do a formal review this weekend.
Comment 37 Kevin Fenzi 2010-08-02 17:16:24 EDT
Peter? You still able to do this review? 

We need it done soon for the feature. ;( 

If not, I will look at doing one.
Comment 38 Peter Robinson 2010-08-02 17:32:00 EDT
Yes. Mostly done (included below). I can't build it in koji or rawhide at the moment and it looks like there's no files included in the base package as I don't see a base %files manifest. According to the home page its a library so I would expect (based on C stuff) that there would be an installable library in the base package and devel in the devel files. Other than that there's a few minor minuses below.

+ rpmlint output

$ rpmlint tango.spec tango-0.99.9-9.20100726svn5508.fc13.src.rpm 
tango.spec: W: invalid-url Source0: tango-20100726svn5508.tar.xz
tango.src: W: spelling-error Summary(en_US) runtime -> run time, run-time, runtish
tango.src: I: enchant-dictionary-not-found fr
tango.src: W: spelling-error %description -l en_US runtime -> run time, run-time, runtish
tango.src: W: spelling-error %description -l fr langage -> language
tango.src: W: invalid-url Source0: tango-20100726svn5508.tar.xz
1 packages and 1 specfiles checked; 0 errors, 5 warnings.

+ package name satisfies the packaging naming guidelines
+ specfile name matches the package base name
+ package should satisfy packaging guidelines
+ license meets guidelines and is acceptable to Fedora
+ license matches the actual package license
+ latest version packaged

+ %doc includes license file
+ spec file written in American English
+ spec file is legible
  upstream sources match sources in the srpm
  
- package successfully builds on at least one architecture
  tested using koji scratch build
+ BuildRequires list all build dependencies
n/a %find_lang instead of %{_datadir}/locale/*
n/a binary RPM with shared library files must call ldconfig in %post and %postun does not use Prefix: /usr
n/a package owns all directories it creates
n/a no duplicate files in %files
+ Package perserves timestamps on install
- Permissions on files must be set properly 
+ %defattr line
+ consistent use of macros
+ package must contain code or permissible content
n/a large documentation files should go in -doc subpackage
+ files marked %doc should not affect package runtime 
+ header files should be in -devel
+ static libraries should be in -static
n/a packages containing pkgconfig (.pc) files need 'Requires: pkgconfig'
n/a libfoo.so must go in -devel
-  devel must require the fully versioned base
+ packages should not contain libtool .la files
n/a packages containing GUI apps must include %{name}.desktop file
+ packages must not own files or directories owned by other packages
+ filenames must be valid UTF-8

Optional:

n/a if there is no license file, packager should query upstream to include it
+ translations of description and summary for non-English languages, if
available
- reviewer should build the package in mock/koji
- the package should build into binary RPMs on all supported architectures
n/a review should test the package functions as described
+ scriptlets should be sane
-  non -devel packages should require fully versioned base
n/a pkgconfig files should go in -devel
+ shouldn't have file dependencies outside /etc /bin /sbin /usr/bin or
/usr/sbin
n/a  Package should have man files
Comment 39 MERCIER Jonathan 2010-08-02 17:50:31 EDT
tomorrows you will can do a scratch build
Comment 40 Peter Robinson 2010-08-03 03:10:09 EDT
So grabbing the latest ldc from koji I can build it locally. I'm not sure why there's a separate -devel package if its all devel as the whole lovely translated description in the main package is completely worthless.

You might also look at splitting out docs (I know it was discussed above) due to them being identical and hence will cause issues in a multilib environment so you might want to look at using a noarch sub package to avoid that.

$ rpmlint tango.spec ../SRPMS/tango-0.99.9-9.20100726svn5508.fc14.src.rpm ../RPMS/x86_64/tango-de*
tango.spec: W: invalid-url Source0: tango-20100726svn5508.tar.xz
tango.src: W: spelling-error Summary(en_US) runtime -> run time, run-time, runtish
tango.src: I: enchant-dictionary-not-found fr
tango.src: W: spelling-error %description -l en_US runtime -> run time, run-time, runtish
tango.src: W: spelling-error %description -l fr langage -> language
tango.src: W: invalid-url Source0: tango-20100726svn5508.tar.xz
tango-debuginfo.x86_64: E: empty-debuginfo-package
tango-devel.x86_64: W: spelling-error %description -l en_US documentaion -> documentation, documentarian, documentarist
tango-devel.x86_64: W: spelling-error %description -l en_US stdout -> stout, std out, std-out
tango-devel.x86_64: W: spelling-error %description -l en_US stderr -> std err, std-err, strider
3 packages and 1 specfiles checked; 1 errors, 8 warnings.

But the debuginfo package needs to be dealt with:
https://fedoraproject.org/wiki/Packaging/Guidelines#Debuginfo_packages
Comment 41 Chen Lei 2010-08-03 03:41:36 EDT
Hi MERCIER,

The spec seems almost fine, I only suggest to replace rm -rf      %{name}/core/rt/compiler with rm -rf      %{name}/core/rt, it seems core/rt is not useful for normally development.

Look at the apidocs of tango[1], the files under core/rt are not documented here at all. Upstream binary tarball[2] also doesn't include this directory.


Another question is there are several different opensource D compilers, is ldc far better than all other compilers(e.g. DMD)? If not, then I suggest to rename libtango.a to libtango-ldc.a as the name in the upstream tarball[2].

[1]http://www.dsource.org/projects/tango/docs/stable/
[2]http://downloads.dsource.org/projects/tango/0.99.9/tango-0.99.9-bin-linux32-ldc.tar.gz
Comment 42 MERCIER Jonathan 2010-08-03 05:49:38 EDT
gdc is compiler using gcc but this project is near to death
dmd ca not packaged for official fedora repo due to licensing
ldc is a compiler using LLVM and they have an active community.
it seems that ldc produced application slightly faster than dmd
Comment 43 MERCIER Jonathan 2010-08-03 06:38:47 EDT
is a last day for review it.
build with koji, http://koji.fedoraproject.org/koji/taskinfo?taskID=2376339

spec with doc and example: http://bioinfornatics.fedorapeople.org/tango.spec
Comment 44 MERCIER Jonathan 2010-08-03 06:39:35 EDT
i replace rm -rf    
%{name}/core/rt/compiler with rm -rf      %{name}/core/rt too
Comment 45 Peter Robinson 2010-08-03 07:07:51 EDT
(In reply to comment #43)
> is a last day for review it.

I'm awaiting a reason why there's nothing in the root package? If its all devel it should just go in the root package. IE is this like vala where its generated code and once compiled it doesn't need the libraries themselves.

> build with koji, http://koji.fedoraproject.org/koji/taskinfo?taskID=2376339
> 
> spec with doc and example: http://bioinfornatics.fedorapeople.org/tango.spec    

Also the koji build is different to the that spec (ie no examples/docs package)

And the manifest is wrong:

%files devel
%defattr(-,root,root,-)
%doc README.txt LICENSE.txt
%files doc
%defattr(-,root,root,-)
%doc doc/html
%files examples
%defattr(-,root,root,-)
%doc doc/example

%{_d_libdir}/libtango.a
%{_d_includedir}/%{name}
%{_d_includedir}/object.di

That will have the bottom 3 lines end up in examples package
Comment 46 MERCIER Jonathan 2010-08-03 07:29:15 EDT
oops yes i miss rebuild src.rpm i fix all
build with good spec:
http://koji.fedoraproject.org/koji/taskinfo?taskID=2376426
Comment 47 Chen Lei 2010-08-03 07:46:31 EDT
Actually, merge doc and examples to -devel subpackage won't cause issues in a multilib environment, because all those files have the same timestamps. If you want to split a -doc subpackage, then I suggest to also move examples files to this -doc subpackage.
Comment 49 MERCIER Jonathan 2010-08-03 08:34:40 EDT
good link: http://koji.fedoraproject.org/koji/taskinfo?taskID=2376575
Comment 50 Chen Lei 2010-08-03 09:34:52 EDT
Seveal remaining issue:

1. As Peter already commented, you should add %global debug_package %{nil} at the top of the spec file. GNU strip can't extract debug symbols from static lib achieves.

2. It'll be better to add BuildArch:              noarch to -doc subpackage

3.Requires:       %{name} = %{version}-%{release}
Provides:       %{name}-docs = %{version}-%{release}
->
Provides is not needed, Requires should be changed to %{name}-devel = %{version}-%{release} since mainpackage is not exist.

4. Some of you summaries and descriptions need further modification to make them more clear.


e.g.
Summary:        It is runtime library for D language of d1 specification
->Summary:       Runtime library for D language of d1 specification
or               The Developer's Library for D

Summary:        Support for developing D application
->              Development files for %{name}

Summary:        Documentation for %{name}
->
Summary:        Documentation and examples for %{name}


description devel is also not very clear, you may need to copy some word from tango mainpackage.

e.g.

Tango is a cross-platform open-source software library, written in the D programming language for D programmers. It is structured as a cohesive and comprehensive library for general purpose usage, and is supported by a growing number of recognized D enthusiasts. 

This package contains static libraries and header files that applications can use to build against tango.
 




Notes: Since mainpackage is empty, add some descrption for tango in -devel subpackage will be more helpful.
Comment 52 MERCIER Jonathan 2010-08-03 10:58:55 EDT
Add BuildArch noarch for -doc sub package
koji: http://koji.fedoraproject.org/koji/taskinfo?taskID=2376889
Comment 53 MERCIER Jonathan 2010-08-04 19:27:07 EDT
the review is done?
Comment 54 Peter Robinson 2010-08-05 02:38:11 EDT
(In reply to comment #53)
> the review is done?    

I'm awaiting a reason why there's nothing in the root package? If its all devel
it should just go in the root package. IE is this like vala where its generated
code and once compiled it doesn't need the libraries themselves.
Comment 55 Chen Lei 2010-08-05 02:54:09 EDT
(In reply to comment #54)
> (In reply to comment #53)
> > the review is done?    
> 
> I'm awaiting a reason why there's nothing in the root package? If its all devel
> it should just go in the root package. IE is this like vala where its generated
> code and once compiled it doesn't need the libraries themselves.    
From Fedora packaging guideline:

Static libraries only. When a package only provides static libraries you can place all the static library files in the *-devel subpackage. When doing this you also must have a virtual Provide for the *-static package:
Comment 56 Peter Robinson 2010-08-05 03:19:34 EDT
Thanks for confirming the query above.

APPROVED!
Comment 57 MERCIER Jonathan 2010-08-05 05:40:46 EDT
New Package GIT Request
=======================
Package Name: tango
Short Description: The Developer's Library for D
Owners: bioinfornatics
Branches: F-13 F-14
Comment 58 MERCIER Jonathan 2010-08-05 05:44:50 EDT
special thanks to Chen lei and Peter Robinson
Comment 59 Kevin Fenzi 2010-08-05 13:00:44 EDT
Git done (by process-git-requests).
Comment 60 Fedora Update System 2010-08-05 18:50:58 EDT
tango-0.99.9-15.20100802svn5517.fc14 has been submitted as an update for Fedora 14.
http://admin.fedoraproject.org/updates/tango-0.99.9-15.20100802svn5517.fc14
Comment 61 Fedora Update System 2010-08-08 08:27:13 EDT
tango-0.99.9-15.20100802svn5517.fc13 has been submitted as an update for Fedora 13.
http://admin.fedoraproject.org/updates/tango-0.99.9-15.20100802svn5517.fc13
Comment 62 Fedora Update System 2010-08-09 21:29:39 EDT
tango-0.99.9-15.20100802svn5517.fc14 has been pushed to the Fedora 14 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 tango'.  You can provide feedback for this update here: http://admin.fedoraproject.org/updates/tango-0.99.9-15.20100802svn5517.fc14
Comment 63 Juan Castro 2010-08-09 21:59:30 EDT
[root@mycomputer ~]# yum --enablerepo=updates-testing install tango
Loaded plugins: fastestmirror, presto, refresh-packagekit
Loading mirror speeds from cached hostfile
 * fedora: fedora.c3sl.ufpr.br
 * livna: rpm.livna.org
 * rpmfusion-free: mirror.hiwaay.net
 * rpmfusion-free-updates: mirror.hiwaay.net
 * rpmfusion-nonfree: mirror.hiwaay.net
 * rpmfusion-nonfree-updates: mirror.hiwaay.net
 * updates: fedora.c3sl.ufpr.br
 * updates-testing: fedora.c3sl.ufpr.br
Setting up Install Process
No package tango available.
Error: Nothing to do
Comment 64 Kevin Fenzi 2010-08-10 12:02:40 EDT
It was only pushed out to updates-testing this morning (2010-08-10). ;)
Comment 65 Fedora Update System 2010-08-10 17:32:07 EDT
tango-0.99.9-15.20100802svn5517.fc13 has been pushed to the Fedora 13 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 66 Juan Castro 2010-08-14 18:44:10 EDT
Tried to build the examples in /usr/share/doc/tango-doc-0.99.9/example with make -f linux.mak, but it seems to need a command called "bud" which I don't have. What is that?

Besides, the example below stopped compiling. I get the following error:

/usr/include/d/tango/core/sync/Atomic.d(23): Error: module intrinsics cannot read file 'ldc/intrinsics.d'

------------------------------
module test;
import tango.io.Stdout: Stdout, Stderr;

void main(){
 uint a = 5;
 uint b = 0;
 //printf same in C
 Stdout.formatln("hello, world");
 //Cout same in C++
 Stdout.formatln("try divide '{}' by '{}'",  a, b);
 //test
 if (b == 0){
  Stderr.formatln("Divide by zero!!");
 }
 else{
  Stdout.formatln("Result: '{}'", a/b);
  Stdout.formatln("Result: '{}'/'{}'='{}'", a, b, a/b);
 }
}
------------------------------
Comment 67 Kevin Fenzi 2010-08-14 18:57:54 EDT
Please do fiile new bugs against the package itself now that it's in fedora. 

https://bugzilla.redhat.com/enter_bug.cgi?product=Fedora&version=rawhide&component=tango

thanks.
Comment 68 MERCIER Jonathan 2010-08-15 08:22:31 EDT
(In reply to comment #63)
> [root@mycomputer ~]# yum --enablerepo=updates-testing install tango
> Loaded plugins: fastestmirror, presto, refresh-packagekit
> Loading mirror speeds from cached hostfile
>  * fedora: fedora.c3sl.ufpr.br
>  * livna: rpm.livna.org
>  * rpmfusion-free: mirror.hiwaay.net
>  * rpmfusion-free-updates: mirror.hiwaay.net
>  * rpmfusion-nonfree: mirror.hiwaay.net
>  * rpmfusion-nonfree-updates: mirror.hiwaay.net
>  * updates: fedora.c3sl.ufpr.br
>  * updates-testing: fedora.c3sl.ufpr.br
> Setting up Install Process
> No package tango available.
> Error: Nothing to do

yes it is a ldc bug, take the last release: https://admin.fedoraproject.org/updates/ldc-0.9.2-16.20100804hg1655.fc13?_csrf_token=e94adff831dde5c083c6b83c4a0962de816dea93

Or you can use D repos for be always up to date: http://repos.fedorapeople.org/
Comment 69 Fedora Update System 2010-08-18 21:23:49 EDT
tango-0.99.9-15.20100802svn5517.fc14 has been pushed to the Fedora 14 stable repository.  If problems still persist, please make note of it in this bug report.
Comment 70 Peter Robinson 2010-08-30 05:33:15 EDT
Jonathon: why is this built in f14 and f13 and not in rawhide?
Comment 71 MERCIER Jonathan 2010-08-30 06:19:18 EDT
i fix it
Comment 72 Juan Castro 2010-08-30 10:01:28 EDT
The tango-doc package seems to be broken in the fedora-D repository -- its version is not the same as the version of tango-devel, which makes yum cry about dependencies when you try to make an update and tango and tango-devel from the official repos are instaled:

----------------------------------------
Setting up Update Process
Resolving Dependencies
--> Running transaction check
---> Package ldc.i686 0:0.9.2-17.20100804hg1655.fc13 set to be updated
--> Processing Dependency: tango-devel = 0.99.9-15.20100802svn5517.fc13 for package: tango-doc-0.99.9-15.20100802svn5517.fc13.noarch
---> Package tango-devel.i686 0:0.99.9-19.20100826svn5543.fc13 set to be updated
--> Finished Dependency Resolution
Error: Package: tango-doc-0.99.9-15.20100802svn5517.fc13.noarch (@updates)
           Requires: tango-devel = 0.99.9-15.20100802svn5517.fc13
           Removing: tango-devel-0.99.9-15.20100802svn5517.fc13.i686 (@updates)
               tango-devel = 0.99.9-15.20100802svn5517.fc13
           Updated By: tango-devel-0.99.9-19.20100826svn5543.fc13.i686 (fedora-D)
               tango-devel = 0.99.9-19.20100826svn5543.fc13
 You could try using --skip-broken to work around the problem
 You could try running: rpm -Va --nofiles --nodigest
----------------------------------------
Comment 73 MERCIER Jonathan 2010-08-30 11:17:57 EDT
i will fix it today
thanks.
Comment 74 Juan Castro 2010-09-06 21:26:37 EDT
It looked fixed... and then it reappeared. It seems tango-doc reverted to 0.99.9-15.20100802svn5517 in the repo. ?????
Comment 75 MERCIER Jonathan 2010-09-07 02:49:34 EDT
do:
# cd /etc/yum.repos.d/
# urlgrabber http://repos.fedorapeople.org/repos/bioinfornatics/D/fedora-D.repo
# yum update



Please last time can you open another bug, this one is closed :)

Thanks for all if you have some problem with D contact me or irc ;)

Note You need to log in before you can comment on or make changes to this bug.