Closed Bug 1111584 Opened 9 years ago Closed 6 years ago

Files from defaults/profile are missing in new profiles when packaged in omni.ja

Categories

(Instantbird Graveyard :: Other, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED WONTFIX

People

(Reporter: mozbugs, Unassigned)

References

Details

Attachments

(2 files, 1 obsolete file)

User Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/39.0.2171.71 Safari/537.36

Steps to reproduce:

I am trying to add a file to the defaults/profile folder so that it becomes a part of every profile that is created. To do this, I am adding the file name to im/app/profile/Makefile (I also add the file to this directory) and im/installer/package-manifest.


Actual results:

The file is copied to the obj-*/dist/bin/defaults/profile folder, along with mimeTypes.rdf, localstore.rdf and prefs.js. The package-manifest also contains these file names. However, on packaging (using mach package), the profile folder is completely excluded from the package and no file is copied, neither the file I created nor the files mentioned above.


Expected results:

The defaults/profile folder and all files in it should have been copied to the defaults folder in the package.
Try this and see if it helps please!
Attachment #8536571 - Flags: feedback?(sukhbir.in)
Status: UNCONFIRMED → NEW
Ever confirmed: true
Whiteboard: [1.6-blocking]
Isn't this included in omni.ja these days?
(In reply to Florian Quèze [:florian] [:flo] from comment #2)
> Isn't this included in omni.ja these days?

Possibly, but it's still a bug. I have confirmed that a new profile created from a local build differs before and after packaging, in that after packaging the only file added is times.json.
Attached patch firstfix.diff (obsolete) — Splinter Review
first attempt at profilefix.diff
(In reply to aleth [:aleth] from comment #1)
> Created attachment 8536571 [details] [diff] [review]
> profilefix.diff
> 
> Try this and see if it helps please!

So I tried and I think the issue persists. I have attached the diff of comm-central (firstfix.diff) to be sure.

(The "testing" file is there in obj-*/dist/bin again, along with the other files. It doesn't get copied to the package though.)
Comment on attachment 8536571 [details] [diff] [review]
Use flags for defaults/profile and drop defaults/profile/US

Review of attachment 8536571 [details] [diff] [review]:
-----------------------------------------------------------------

We should take this port to be in sync with TB, even though it doesn't fix this bug.
Attachment #8536571 - Flags: feedback?(sukhbir.in) → review?(florian)
(In reply to sukhbir.in from comment #5)
> (The "testing" file is there in obj-*/dist/bin again, along with the other
> files. It doesn't get copied to the package though.)

This isn't correct. The files are packaged, but in omni.ja. The problem is that on creation of a new profile, they are not copied into it.
Summary: Unable to package the defaults/profile folder → Files from defaults/profile are missing in new profiles when packaged in omni.ja
Attachment #8536616 - Attachment is obsolete: true
Attachment #8536571 - Attachment description: profilefix.diff → Use flags for defaults/profile and drop defaults/profile/US
Depends on: 1111670
(In reply to aleth [:aleth] from comment #7)
> (In reply to sukhbir.in from comment #5)
> > (The "testing" file is there in obj-*/dist/bin again, along with the other
> > files. It doesn't get copied to the package though.)
> 
> This isn't correct. The files are packaged, but in omni.ja. The problem is
> that on creation of a new profile, they are not copied into it.

Ah yes, that's true. Just confirmed. Sorry, I have overlooked this. The "testing" file is indeed in omni.ja.
No longer depends on: 1111670
(In reply to sukhbir.in from comment #8)

Could you please put back the dependency you removed? ;)
Depends on: 1111670
Attachment #8536571 - Flags: review?(florian) → review+
From bsmedberg's comments on the platform bug, it appears support for adding files in defaults/profile is no longer officially supported. However, unless that bug sees some action soon, it's likely nothing much will change for now.

So I suggest you add the files to NON_OMNIJAR_FILES in the makefile, that should make the profile initializer find them.
(In reply to aleth [:aleth] from comment #10)
> From bsmedberg's comments on the platform bug, it appears support for adding
> files in defaults/profile is no longer officially supported. However, unless
> that bug sees some action soon, it's likely nothing much will change for now.
> 
> So I suggest you add the files to NON_OMNIJAR_FILES in the makefile, that
> should make the profile initializer find them.

Just to make it clear, should I be adding the files to im/app/profile/ (and the makefile in that directory), and then reference them using NON_OMNIJAR_FILES in im/installer/Makefile?
(In reply to sukhbir.in from comment #11)
> (In reply to aleth [:aleth] from comment #10)
> > From bsmedberg's comments on the platform bug, it appears support for adding
> > files in defaults/profile is no longer officially supported. However, unless
> > that bug sees some action soon, it's likely nothing much will change for now.
> > 
> > So I suggest you add the files to NON_OMNIJAR_FILES in the makefile, that
> > should make the profile initializer find them.
> 
> Just to make it clear, should I be adding the files to im/app/profile/ (and
> the makefile in that directory), and then reference them using
> NON_OMNIJAR_FILES in im/installer/Makefile?

I guess you have to add the file normally to the im/app/profile makefile, and then in the im/installer makefile do something like 

NON_OMNIJAR_FILES = \
    defaults/profile/yourfile \
    $(NULL)

Just experiment ;)
(In reply to aleth [:aleth] from comment #12)
> (In reply to sukhbir.in from comment #11)
> > (In reply to aleth [:aleth] from comment #10)
> > > From bsmedberg's comments on the platform bug, it appears support for adding
> > > files in defaults/profile is no longer officially supported. However, unless
> > > that bug sees some action soon, it's likely nothing much will change for now.
> > > 
> > > So I suggest you add the files to NON_OMNIJAR_FILES in the makefile, that
> > > should make the profile initializer find them.
> > 
> > Just to make it clear, should I be adding the files to im/app/profile/ (and
> > the makefile in that directory), and then reference them using
> > NON_OMNIJAR_FILES in im/installer/Makefile?
> 
> I guess you have to add the file normally to the im/app/profile makefile,
> and then in the im/installer makefile do something like 
> 
> NON_OMNIJAR_FILES = \
>     defaults/profile/yourfile \
>     $(NULL)
> 
> Just experiment ;)

Thanks, that worked. I have attached a patch with a sample file called "testing" which is included in defaults/profile and therefore is copied to any profile that is created.
Whiteboard: [1.6-blocking]
Is this "fixed" then or no?
(In reply to Patrick Cloke [:clokep] from comment #15)
> Is this "fixed" then or no?

No. We could use something similar to comment 12 for the files which are nominally packaged in defaults/profile, but Firefox doesn't do this either. According to the discussion in the linked bug, this is dead code and if it gets removed that workaround will also likely break.
On the behalf of Florian:
Closing bugs related to the Instantbird UI as WONTFIX, as the development of the standalone chat client Instantbird has stopped. Instantbird users are encouraged to migrate to Thunderbird. The user interface of instant messaging in Thunderbird will feel familiar, as the Thunderbird IM support started as a fork of Instantbird.
Status: NEW → RESOLVED
Closed: 6 years ago
Resolution: --- → WONTFIX
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: