Skip to content

Deprecate unsupported exporters #4742

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
Jul 27, 2017

Conversation

theotherjimmy
Copy link
Contributor

@theotherjimmy theotherjimmy commented Jul 11, 2017

These exporters are planned for removal in mbed OS 5.6. To keep an exporter
around, a pull request to remove one of the "Deprecate *" commits should be
submitted against mbed-os along with an update to that exporer to make it
better conform to the best practices of an exporter from the
"adding exporters" documentation. For your convinience, the applicable section
is reproduced below:

For the best user experience, an exporter:

  • Takes input from the resource scan.
  • Uses the flags in the build profiles.
  • Has a single template file for each file type they produce. For example, an eclipse CDT project would have one template for .project files and one for .cproject files.
  • Does not call mbed CLI. It is possible to export from the website, which will not include mbed CLI in the resulting zip.

@janjongboom
Copy link
Contributor

janjongboom commented Jul 12, 2017

Can't we fix these instead of remove them? Do we have any data on the usage of these exporters?

@0xc0170
Copy link
Contributor

0xc0170 commented Jul 12, 2017

Can't we fix these instead of remove them? Do we have any data on the usage of these exporters?

Good questions !

I'll add here contributors for these exporters to be aware
cc @stevew817 @akselsm @mmahadevan108 @arostm @bcostm @TomoYamanaka

@theotherjimmy
Copy link
Contributor Author

@janjongboom I would love to have them fixed, but they really should be supported by the respective partner. I specifically put a blurb about how to get the exporters not-deprecated in the description for that purpose.

@JojoS62
Copy link
Contributor

JojoS62 commented Jul 17, 2017

I raise my hand also for keeping and fixing and would help with that.

Yesterday I was disappointed because I'm still using mbed2 (mbed-os is too large for tiny targets) and the 'gnuarmeclipse' exporter was not availible. It took me until today to find out that it is in the mbed-sdk-tools mercurial repo, not in the github projects. A note in the mbed-cli about updating the command and the tools would be fine.

Actually, the gnuarmeclipse exporter for mbed2 also has two problems:

  1. there are some wrappers defined but the wrapped functions are not existing in OS2
  2. in .temp/tools/data/rpc are sourcefiles which do not belong to the mbed project but are scanned by the CDT scanner. I could fix this by adding an exclude in the resources, this are a few lines in the .project template. If this is not already an issue, I can create one later.
    Are there already issues for this?

I think for the LPC targets the LPCXpresso and now the successor MCUXpresso has some more debugging support. So I want to try again to fix this exporter and I also want to have the option to build a seperated project with only the target files for a particular target. Basically, I got this working manually:

  • create a mbed-classic project with mbed-cli
  • create a eclipse-project subdir
  • copy the project sources, mbed/drivers, /hal, /platform and target dir
    run 'mbed export -i lpcxpresso --source my_project''
    This will create the .cproject and .project files in the subdir .\myproject. The thing to fix for this is that all path contain 'workspace_dir\myproject', where workspace_dir is not needed. When this is fixed, some linker errors remain but these can be fixed also.

Now there are target specific templates for this exporter, but I think these are not necessary and the IDE will create the necessary settings itself by selecting the right target MCU. So I will check if the 'single template file' requirement can be fullfilled.

@theotherjimmy
Copy link
Contributor Author

@JojoS62 I updated the mbed2 tools to follow the 5.5.2 release of mbed OS on Friday. Thanks for the feedback on them. I'm so happy that you're looking into updating the lpcxpresso exporter! I will remove the deprecation notice from this PR when I see your PR (That's why they are all separate commits).

@janjongboom @JojoS62 I'm quite happy to keep exporters. I will gladly remove deprecations from this PR, or if this PR is merged, revert the appropriate commits upon update of the offending exporter. Note that some of these IDEs may be superseded, so deprecating their exporter and replacing it with the new one may be in order.

@theotherjimmy
Copy link
Contributor Author

@JojoS62 Feel free to submit an exporter PR in a broken/not working state. I will help out with hashing out the implementation.

@JojoS62
Copy link
Contributor

JojoS62 commented Jul 17, 2017

Thanks!
One thing I could check when I removed the target specific part from the .cproject, the build will complain about missing MCU settings. Then during the build a dialog pops up for selecting the MCU. This happens once and the IDE adds the MCU setting. I think this can be expected of the user to select the MCU in favor of having single template files?

@JojoS62
Copy link
Contributor

JojoS62 commented Jul 17, 2017

@theotherjimmy I'm trying to trigger the zipfile option. but when I pass "--source None" the exporter complains. In OS2, the code looks strange: (line 268)

    for mcu in options.mcu:
        zip_proj = not bool(options.source_dir)

When I force zip_proj = True, the zip file is created in OS5. Couldn't be the project.py files the same in OS2 and 5? The zip file contains what eclipse needs for the import. Is this function also used by the online compiler?

@theotherjimmy
Copy link
Contributor Author

@JojoS62

Couldn't be the project.py files the same in OS2 and 5?

They should be

Is this function also used by the online compiler?

Yep.

@theotherjimmy
Copy link
Contributor Author

When you say OS 2, are you trying to do mbed export -n <mbed-2-test>? That probably won't work from mbed CLI.

@JojoS62
Copy link
Contributor

JojoS62 commented Jul 17, 2017

They should be

ok, they are not, I checked line 238 in project.py in the repos mbed-sdk-tools. I will try to use the mbed-os version tomorrow.

When you say OS 2, are you trying to

No, I have created two projects with mbed-cli, one is a mbed-os and the other a mbed-classic . There I start the export tests.

@JojoS62
Copy link
Contributor

JojoS62 commented Jul 17, 2017

ok, with forcing zip_file = True in the code I can create a .zip for my project in OS2 also. I accidently deleted .mbed in the .\export subdir, that caused the an file not found error.
Now this is a good base to create projects that can be imported by lpcxpresso.

@theotherjimmy
Copy link
Contributor Author

#4779 Let's not deprecate SW4STM32.

@0xc0170
Copy link
Contributor

0xc0170 commented Jul 24, 2017

I restarted jenkins CI as it was a problem with resources from the last week, should rerun soon.

@theotherjimmy What is the status of this PR? I assume its ready for CI run?

@theotherjimmy
Copy link
Contributor Author

/morph export-build

@mbed-bot
Copy link

Result: SUCCESS

Your command has finished executing! Here's what you wrote!

/morph export-build

Output

mbed Build Number: 89

All exports and builds passed!

@TomoYamanaka
Copy link
Contributor

@theotherjimmy

We have a few questions against this PR.

From contents of this PR, we read that mbed Exporter function will be not support e2 studio from now on. Is our recognition right?
Or, do this PR means that e2 studio become un-support in the temporary but it will become support again by another PR?

In addition,
we Renesas is working on the improvement of Exporter function(refer to Refurbish_exporters.md) you showed to us previously.
Could you please tell us the relevance with this?

@theotherjimmy
Copy link
Contributor Author

Is our recognition right?

Kind of. You are correct in pointing out that the exporter is not supported, but it still functions.

do this PR means that e2 studio become un-support in the temporary but it will become support again by another PR?

That depends on your plans. I don't plan on making a PR it support the e2 studio exporter. If you or someone else did, I will remove the deprecation notice, as it is now supported by that person.

we Renesas is working on the improvement of Exporter function(refer to Refurbish_exporters.md) you showed to us previously.

Sounds like we'll be removing the deprecation notice soon then.

Could you please tell us the relevance with this?

This PR marks them as "not currently supported" but leaves the code in. I have already removed the SW4STM32 exporter from the list of deprecated exporters because of #4779. If you or someone else publishes a similar PR for e2 studio, I will remove the "Deprecate e2studio" commit from this series, if it's not merged yet, or ask you to add a revert commit to your PR if this PR comes in first.

@TomoYamanaka
Copy link
Contributor

TomoYamanaka commented Jul 27, 2017

@theotherjimmy

Thank you for your comments.

After "export to e2 studio" was no longer supported by this PR,
can I export to e2 studio on Online Compiler if I use older version of mbed OS or mbed lib?

@theotherjimmy
Copy link
Contributor Author

can I export to e2 studio on Online Compiler if I use older version of mbed OS or mbed lib?

Yes. Until it is removed from the mbed OS code base, you can still export.

@theotherjimmy theotherjimmy merged commit d2ad886 into ARMmbed:master Jul 27, 2017
@theotherjimmy theotherjimmy deleted the deprecate-exporters branch July 27, 2017 14:40
@TomoYamanaka
Copy link
Contributor

TomoYamanaka commented Jul 28, 2017

@theotherjimmy

Sorry that my question was not enough.
For for confirmation , please let me ask again.
Would we be able to export the e2Studio project on online compiler when we use the older mbed OS 5 (e.g. mbed OS 5.4.x) even after mbed OS this PR was merged would be available?

@TomoYamanaka
Copy link
Contributor

@theotherjimmy

Sorry to bother you again.

Sorry that my question was not enough.
For for confirmation , please let me ask again.
Would we be able to export the e2Studio project on online compiler when we use the older mbed OS 5 (e.g. mbed OS 5.4.x) even after mbed OS this PR was merged would be available?

I'd appreciate if you could answer the above question.

@theotherjimmy
Copy link
Contributor Author

Would we be able to export the e2Studio project on online compiler when we use the older mbed OS 5 (e.g. mbed OS 5.4.x) even after mbed OS this PR was merged would be available?

Alright, I'll answer again. Yes. Until I REMOVE the exporter it will still work. The exporter is currently DEPRECATED which means:

the discouragement of use of some terminology, feature, design, or practice; typically because it has been superseded or is no longer considered efficient or safe – but without completely removing it or prohibiting its use.

@TomoYamanaka
Copy link
Contributor

@theotherjimmy

Thank you.
I appreciate for your kindly and prompt response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants